Measuring PHP Page Load Time script?

Hi,

Do you have an idea how measuring php page load time with Scriptcase ?

By example, if I want to show it on footer page.

Thanks

echo ‘Exact time taken to run: ’ . (microtime(true) - $_SERVER[‘REQUEST_TIME_FLOAT’]) . ’ seconds’;
OR
$time_start = microtime(true); //set this on Init and make a sess var with it??

then On Footer:

$time_end = microtime(true);
$seconds = ($time_end - $time_start)/60;
echo “This script took $seconds to execute.”;///

1 Like

Thank you.

I didn’t know REQUEST_TIME_FLOAT method, is it a precise and reliable solution ?

Otherwise actually, I can use another method with global var.

Thanks

1 Like

Here is, my solution with Dashboad app.

With french version :

I have not error message from Dashboard app, but with repport app, there is a error :

Parse error: syntax error, unexpected '"', expecting identifier (T_STRING) in

Thanks

1 Like