NOTE:: Before reporting an issue, make sure you are running the latest version, currently 3.3.1

View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0015512phplist applicationClick Trackingpublic04-07-10 14:2126-03-13 16:14
PlatformOSOS Version
Product Version2.10.10 
Target Version4.0.xFixed in Version2.11.8 
Summary0015512: Converting statistical responsetime from seconds to h:m:s
DescriptionFeature request by gcd:
===== Start quote =====
We find the click stats useful, but the responsetime displayed by /admin/mviews.php is in seconds, and therefore difficult for a human to process. We've convert it to hours:minutes:seconds by changing line 136 (in v2.10.10) to use gmdate():

$ls->addColumn($element,$GLOBALS['I18N']->get('responsetime'),$row['responsetime'].' '.$GLOBALS['I18N']->get('sec'));

$ls->addColumn($element,$GLOBALS['I18N']->get('responsetime'),gmdate("H:i:s", $row['responsetime']));

Might want to consider that for future versions.
Thanks for the great tool! :D
===== End quote =====
ref: [^]
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
h2b2 (manager)
04-07-10 17:14

On a similar note dlynes suggests this mod:

===== Start quote =====

I've modified the code to show response time in days, hours, minutes and seconds instead of just seconds.

It may or may not be good for languages other than English or French, as I'm not using the I18N globals array for the separators, but I hope you still find the code useful:

Replace line 136 in mviews.php:
$ls->addColumn($element,$GLOBALS['I18N']->get('responsetime'),$row['responsetime'].' '.$GLOBALS['I18N']->get('sec'));

$rtdays=(int)($row['responsetime']/3600/24) ;
$rthours=(int)(($row['responsetime']-$rtdays*3600*24)/3600) ;
$rtminutes=(int)(($row['responsetime']-$rtdays*3600*24-$rthours*3600)/60) ;
$rtseconds=($row['responsetime']-$rtdays*3600*24-$rthours*3600-$rtminutes*60) ;
$ls->addColumn($element,$GLOBALS['I18N']->get('responsetime'),$rtdays . 'd:' . $rthours . 'h:' . $rtminutes . 'm:' . $rtseconds . 's');

===== End quote =====
ref: [^]
gazouteast (reporter)
27-09-10 10:30


+1 requesting this switch to human-understandable periods, rather than just number of seconds


Copyright © 2000 - 2017 MantisBT Team
Powered by Mantis Bugtracker