Changeset 19611 for trunk/wp-includes/wp-db.php
- Timestamp:
- 12/20/2011 09:36:53 PM (14 years ago)
- File:
-
- 1 edited
-
trunk/wp-includes/wp-db.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/wp-db.php
r19593 r19611 1442 1442 */ 1443 1443 function timer_start() { 1444 $mtime = explode( ' ', microtime() ); 1445 $this->time_start = $mtime[1] + $mtime[0]; 1444 $this->time_start = microtime( true ); 1446 1445 return true; 1447 1446 } … … 1452 1451 * @since 1.5.0 1453 1452 * 1454 * @return int Total time spent on the query, in milliseconds1453 * @return float Total time spent on the query, in seconds 1455 1454 */ 1456 1455 function timer_stop() { 1457 $mtime = explode( ' ', microtime() ); 1458 $time_end = $mtime[1] + $mtime[0]; 1459 $time_total = $time_end - $this->time_start; 1460 return $time_total; 1456 return ( microtime( true ) - $this->time_start ); 1461 1457 } 1462 1458
Note: See TracChangeset
for help on using the changeset viewer.