note 46585 deleted from function.eval by curt

From: Date: Sat, 16 Oct 2004 04:40:22 +0000
Subject: note 46585 deleted from function.eval by curt
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-78639@lists.php.net to get a copy of this message
Note Submitter: dev at kiwicore dot org ---- Use this function to check syntax if you don't have PHP5. It has the same shortcomings as php_check_syntax, in that it actually executes the code, so never run this on anything the public would submit to your site. list($success,$response) = encapsulatedEval($yourCode); function encapsulatedEval($code){ ob_start(); eval($code); $str = ob_get_contents(); ob_clean(); return array(empty($str),$str); } ---- Reason: bad code

« previous php.notes (#78639) next »