Casey Chu wrote:
Yeah, try testing. Maybe something like this:
<?php
$form = "<form action=' ' method='post'><textarea
name='code'></textarea><br /><button
type='submit'>Execute</button></form>";
if ($_POST['code']) {
 echo "<div style='border: 1px'>";
  $time_start = microtime_float();
  eval($_POST['code']);
  $time_end = microtime_float();
 echo "<br />Loading took: ". $time_end - $time_start. '</div>';
 }
echo "<div style='float: left'>$form</div>";
// Note: This script is extremely dangerous and is not tested.
?>
I haven't been following this thread, so I don't know if this has been suggested...

If you can run a local server, IMO, xdebug is *the* way to go...xdebug2 has an excellent profiler built-in. You can use kcachegrind or wincachegrind to see some pretty mind-boggling detail about where your performance goes. It's much easier than inserting timing statements into existing code.

jon

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to