note 55282 modified in function.eval by danbrown

From: Date: Tue, 25 Nov 2008 16:07:58 +0000
Subject: note 55282 modified in function.eval by danbrown
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-146944@lists.php.net to get a copy of this message
Using the html_eval() some notes above I experienced problems related to *dirty* html. This function is less critical: <?php function html_eval2($string) { return preg_replace_callback("/<\?php(.*?)\?>/","my_eval",$string); } function my_eval($arr) { return eval($arr[1]); } ?> Timo --was-- Using the html_eval() some notes above I experienced problems related to *dirty* html. This function is less critical: function html_eval2($string) { return preg_replace_callback("/<\?php(.*?)\?>/","my_eval",$string); } function my_eval($arr) { return eval($arr[1]); } Timo http://php.net/manual/en/function.eval.php

« previous php.notes (#146944) next »