r114593 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r114592‎ | r114593 | r114594 >
Date:05:52, 29 March 2012
Author:a_engels
Status:new
Tags:
Comment:
Phil's request
Modified paths:
  • /trunk/wikistats/squids/SquidReportArchive.pl (modified) (history)

Diff [purge]

Index: trunk/wikistats/squids/SquidReportArchive.pl
@@ -4463,32 +4463,32 @@
44644464 my $total_html = $countua {'T', '.', 'page', '.'} ;
44654465 my $api_multiplier = $countua {'S', '.', 'page', '.'} / $countua {'S', '.', '.', 'opensearch' } ;
44664466
4467 - $mobile_browsers_all = &ShowCount ($countua {'M', '.', '.', '.'}) ;
 4467+ $mobile_browsers_all = &ShowCount ($countua {'M', '.', '.', '.'}, $marker_color) ;
44684468 $mobile_browsers_all_mobile = &ShowCount ($countua {'M', 'M', '.', '.'}) ;
44694469 $mobile_browsers_all_main = &ShowCount ($countua {'M', 'W', '.', '.'}) ;
44704470 $mobile_browsers_all_others = &ShowCount ($countua {'M', 'X', '.', '.'}) ;
4471 - $mobile_browsers_all_perc = &ShowPerc (100 * $countua {'M', '.', '.', '.'} / $total_count ) ;
 4471+ $mobile_browsers_all_perc = &ShowPerc (100 * $countua {'M', '.', '.', '.'} / $total_count, $marker_color ) ;
44724472
4473 - $mobile_browsers_html = &ShowCount ($countua {'M', '.', 'page', '.'}) ;
 4473+ $mobile_browsers_html = &ShowCount ($countua {'M', '.', 'page', '.'}, $marker_color) ;
44744474 $mobile_browsers_html_mobile = &ShowCount ($countua {'M', 'M', 'page', '.'}) ;
44754475 $mobile_browsers_html_main = &ShowCount ($countua {'M', 'W', 'page', '.'}) ;
44764476 $mobile_browsers_html_others = &ShowCount ($countua {'M', 'X', 'page', '.'}) ;
4477 - $mobile_browsers_html_perc = &ShowPerc (100 * $countua {'M', '.', 'page', '.'} / $total_html ) ;
 4477+ $mobile_browsers_html_perc = &ShowPerc (100 * $countua {'M', '.', 'page', '.'} / $total_html, $marker_color ) ;
44784478
4479 - $mobile_browsers_images = &ShowCount ($countua {'M', '.', 'image', '.'}) ;
4480 - $mobile_browsers_other = &ShowCount ($countua {'M', '.', 'other', '.'}) ;
 4479+ $mobile_browsers_images = &ShowCount ($countua {'M', '.', 'image', '.'}, $marker_color) ;
 4480+ $mobile_browsers_other = &ShowCount ($countua {'M', '.', 'other', '.'}, $marker_color) ;
44814481
4482 - $mobile_browsers_estimate = &ShowCount (floor($countua {'M', '.', '.', 'opensearch' } * $api_multiplier + 0.5)) ;
4483 - $mobile_browsers_estimate_perc = &ShowPerc (100 * $countua {'M', '.', '.', 'opensearch' } * $api_multiplier / $total_html) ;
 4482+ $mobile_browsers_estimate = &ShowCount (floor($countua {'M', '.', '.', 'opensearch' } * $api_multiplier + 0.5), $marker_color) ;
 4483+ $mobile_browsers_estimate_perc = &ShowPerc (100 * $countua {'M', '.', '.', 'opensearch' } * $api_multiplier / $total_html, $marker_color) ;
44844484
44854485 $html .= "<tr>" .
44864486 "<td class=lt><b>Mobile browsers</b><br>&nbsp;&nbsp;(to mobile site)<br>&nbsp;&nbsp;(to main site)<br>&nbsp;&nbsp;(others)</td>\n" .
4487 - "<td class=rt>$mobile_browsers_all<br>$mobile_browsers_all_mobile<br>$mobile_browsers_all_main<br>$mobile_browsers_all_others</td>" .
4488 - "<td class=rt>$mobile_browsers_all_perc</td>\n" .
4489 - "<td class=rt>$mobile_browsers_html<br>$mobile_browsers_html_mobile<br>$mobile_browsers_html_main<br>$mobile_browsers_html_others</td></td><td class=rt>$mobile_browsers_html_perc</td>\n" .
4490 - "<td class=rt>$mobile_browsers_images</td>\n" .
4491 - "<td class=rt>$mobile_browsers_other</td>\n" .
4492 - "<td class=rt>$mobile_browsers_estimate</td><td class=rt>$mobile_browsers_estimate_perc</td>" .
 4487+ "<td class=rt><b>$mobile_browsers_all</b><br>$mobile_browsers_all_mobile<br>$mobile_browsers_all_main<br>$mobile_browsers_all_others</td>" .
 4488+ "<td class=rt><b>$mobile_browsers_all_perc</b></td>\n" .
 4489+ "<td class=rt><b>$mobile_browsers_html</b><br>$mobile_browsers_html_mobile<br>$mobile_browsers_html_main<br>$mobile_browsers_html_others</td></td><td class=rt><b>$mobile_browsers_html_perc</b></td>\n" .
 4490+ "<td class=rt><b>$mobile_browsers_images</b></td>\n" .
 4491+ "<td class=rt><b>$mobile_browsers_other</b></td>\n" .
 4492+ "<td class=rt><b>$mobile_browsers_estimate</b></td><td class=rt><b>$mobile_browsers_estimate_perc</b></td>" .
44934493 "</tr>\n" ;
44944494
44954495 $android_wikimedia_all = &ShowCount ($countua {'A', '.', '.', '.'}) ;