$val) { $total += $val['count']; } // Sort the data by most hits function compare($a, $b) { if ($a['count'] == $b['count']) { return 0; } else return (($a['count'] < $b['count']) ? 1 : -1); } uasort($names, 'compare'); // Lets start our web page ?> Specific Browser Statistics
Specific Browser Statistics $val) { echo "\n"; // The Number echo '\n"; // The Count echo "\n"; $cuml += $val['count']; // The Percent printf("\n", 100.00 * ($val['count'] / $total)); // The Name echo "\n"; // The cuml % printf("\n", 100.00 * ($cuml / $total)); print "\n"; } // End everything up ... ?>
No. Hits Browser Cuml
', $count++, "{$val['count']}  %.2f%%  {$one}"; // If it has subs ... if ($val['subs']) { // Print them echo "\n"; // Sort them ... arsort($val['subs']); foreach ($val['subs'] as $sb => $sbnum) { echo "\n"; // The hits echo "\n"; // The % printf("\n", 100.00 * ($sbnum / $val['count'])); // The Name echo "\n"; echo "\n"; } echo "
 {$sbnum}  %.2f%%  {$sb}
"; } // Finish the Name echo "
 %.2f%%


Statisics generated by specific_browser.php v1.0