@ini_set( "display_errors", true );
# In case of errors, let output be clean.
-$wgRequestTime = microtime();
+$wgRequestTime = microtime( true );
# Attempt to set up the include path, to fix problems with relative includes
$IP = dirname( dirname( __FILE__ ) );
global $wgProfiling, $wgUser;
$now = wfTime();
- list( $usec, $sec ) = explode( ' ', $wgRequestTime );
- $start = (float)$sec + (float)$usec;
- $elapsed = $now - $start;
+ $elapsed = $now - $wgRequestTime;
if ( $wgProfiling ) {
- $prof = wfGetProfilingOutput( $start, $elapsed );
+ $prof = wfGetProfilingOutput( $wgRequestTime, $elapsed );
$forward = '';
if( !empty( $_SERVER['HTTP_X_FORWARDED_FOR'] ) )
$forward = ' forwarded for ' . $_SERVER['HTTP_X_FORWARDED_FOR'];
global $wgRequestTime;
$now = wfTime();
- list( $usec, $sec ) = explode( ' ', $wgRequestTime );
- $start = (float)$sec + (float)$usec;
- $elapsed = $now - $start;
+ $elapsed = $now - $wgRequestTime;
$com = sprintf( "<!-- Served by %s in %01.3f secs. -->",
wfHostname(), $elapsed );