From 0247349e8208972608f5f693ed47b7f2457b8c60 Mon Sep 17 00:00:00 2001 From: marcus Date: Tue, 17 Feb 2009 08:44:06 +0000 Subject: Added some very basic page load profiling. git-svn-id: https://code.elgg.org/elgg/trunk@2776 36083f99-b078-4883-b0ff-0f9b5a30f544 --- engine/lib/elgglib.php | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'engine/lib') diff --git a/engine/lib/elgglib.php b/engine/lib/elgglib.php index 9d677a483..81c38e0d5 100644 --- a/engine/lib/elgglib.php +++ b/engine/lib/elgglib.php @@ -2167,7 +2167,12 @@ */ function __elgg_shutdown_hook() { + global $CONFIG, $START_MICROTIME; + trigger_elgg_event('shutdown', 'system'); + + if ($CONFIG->debug) + error_log("Page {$_SERVER['REQUEST_URI']} generated in ".(float)(microtime(true)-$START_MICROTIME)." seconds"); } function elgg_init() { -- cgit v1.2.3