Count number of pages for each month in the Date Navigation

Permalink
I have a date navigation block in a section of my website, and I have created a custom template for it so that I can edit the view.php, i'm just not sure how to go about achieving what i need to.

After the month name I want to add in brackets the number of pages for this month. I know how to add the code to print it out to the screen i'm just not sure how to go about calculating the number of pages for that month?

This is the code to print out the count to the screen;

echo "\t <div class='section trigger ".$monthClosed." month".$month.'_'.$year."'>".t(date($monthDisplayFormat,mktime(0,0,0,$month,1,$year)))." (".count(<<countofwhat??>>).")</div> \r \n";