WordPress.org

Ready to get started?Download WordPress

Codex

Function Reference/timer stop

Contents

Description

This function returns the amount of time (in seconds) to generate the page.

Usage

 <?php timer_stop$display 0$precision ); ?> 

Example

Usage

Determine length of time to render page with a precision of 3, 5 and 10 digits.

<?php echo('Seconds: '.timer_stop( 0 ).'<br />'); ?>
<?php echo('Seconds: '.timer_stop( 0, 5 ).'<br />'); ?>
<?php echo('Seconds: '.timer_stop( 0, 10 ).'<br />'; ?>

Seconds: 0.815
Seconds: 0.81551
Seconds: 0.8155429363

Parameters

display 
(integer) Possible values: 0 or 1. Defaults to 0.
precision 
(integer) Possible values: 0 or 1. Defaults to 3.

Related Functions

timer_start

Further Reading

For a comprehensive list of functions, take a look at the category Functions

Also, see Function_Reference