<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -19,12 +19,18 @@ $watch   = getHtmlUserList($watch);
 $ical    = &quot;webcal://upcoming.yahoo.com/calendar/v2/event/&quot;.UPCOMING_EVENT;
 $sign_up = &quot;http://upcoming.yahoo.com/event/&quot;.UPCOMING_EVENT.&quot;/&quot;;
 
+$attend_num = getUserCount($data-&gt;attend);
+$attend_num = ($attend_num) ? &quot; ($attend_num)&quot; : '';
+
+$watch_num  = getUserCount($data-&gt;watch);
+$watch_num  = ($watch_num)  ? &quot; ($watch_num)&quot;  : '';
+
 mb_internal_encoding(&quot;UTF-8&quot;);
 
 $template = getTemplate();
 
-$template = str_replace( array('###attend###', '###watch###', '###ical###', '###sign-up###'),
-                         array($attend, $watch, $ical, $sign_up),
+$template = str_replace( array('###attend###', '###watch###', '###ical###', '###sign-up###', '###attend-num###', '###watch-num###'),
+                         array($attend, $watch, $ical, $sign_up, $attend_num, $watch_num),
                          $template );
 saveOutput($template);
 
@@ -69,4 +75,18 @@ function getHtmlUserList($html) {
     return $output;
 }
 
+function getUserCount($html) {
+    $doc = new DOMDocument();
+    // have to give charset otherwise loadHTML gets confused
+    $doc-&gt;loadHTML(
+        '&lt;html&gt;&lt;head&gt;&lt;meta http-equiv=&quot;content-type&quot; content=&quot;text/html; charset=utf-8&quot;&gt;&lt;/head&gt;&lt;body&gt;'.
+        $html.
+        '&lt;/body&gt;&lt;/html&gt;'
+    );
+    $xpath = new DOMXPath($doc);
+    $items = $xpath-&gt;query(&quot;//a[@property='vcard:fn']&quot;);
+
+    return $items-&gt;length;
+}
+
 ?&gt;
\ No newline at end of file</diff>
      <filename>refresh.php</filename>
    </modified>
    <modified>
      <diff>@@ -198,12 +198,12 @@
                             &lt;h2 class=&quot;hd&quot;&gt;Who's coming?&lt;/h2&gt;
                             &lt;div class=&quot;bd&quot;&gt;
                                 &lt;div class=&quot;yui-u first mod&quot;&gt;
-                                    &lt;h3 class=&quot;hd&quot;&gt;Attending&lt;/h3&gt;
+                                    &lt;h3 class=&quot;hd&quot;&gt;Attending###attend-num###&lt;/h3&gt;
                                     ###attend###
                                 &lt;/div&gt;
 
                                 &lt;div class=&quot;yui-u mod&quot;&gt;
-                                    &lt;h3 class=&quot;hd&quot;&gt;Interested&lt;/h3&gt;
+                                    &lt;h3 class=&quot;hd&quot;&gt;Interested###watch-num###&lt;/h3&gt;
                                     ###watch###
                                 &lt;/div&gt;
                             &lt;/div&gt;</diff>
      <filename>templates/index.tpl</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>15445a1d093857f7d508ceec2c9a26eee3f7bf43</id>
    </parent>
  </parents>
  <author>
    <name>Neil Crosby</name>
    <email>neil@thetenwordreview.com</email>
  </author>
  <url>http://github.com/NeilCrosby/biggeekdayout/commit/3c6a71a79896d80b17afc03c443268bcd8b31b79</url>
  <id>3c6a71a79896d80b17afc03c443268bcd8b31b79</id>
  <committed-date>2009-06-17T12:13:47-07:00</committed-date>
  <authored-date>2009-06-17T12:13:47-07:00</authored-date>
  <message>Added counts for watching and attending</message>
  <tree>8f432ac7cf70acf11efeae741481131b4d5fcd50</tree>
  <committer>
    <name>Neil Crosby</name>
    <email>neil@thetenwordreview.com</email>
  </committer>
</commit>
