You need some kind of measurement to figure out what's wrong. Try to start by putting a basic timer in to your php-script and print the result out at the bottom of the page. That'll tell you if it's the script that takes long, or if it happens beforehand. Eg. at the top of your page put this:
PHP Code:
$GLOBALS['time_start'] = microtime(true);
And at the bottom of your page, put this:
PHP Code:
print "<p>Page rendered in " . number_format((microtime(true) - $GLOBALS['time_start']) * 1000, 4) . " ms</p>";
Bookmarks