mirror of
https://github.com/smarty-php/smarty.git
synced 2025-08-04 18:34:27 +02:00
fixed propagation of $this into evald code in smarty_function_eval()
This commit is contained in:
@@ -32,6 +32,7 @@ function smarty_function_eval($params, &$smarty)
|
||||
$smarty->_compile_source('evaluated template', $params['var'], $_var_compiled);
|
||||
|
||||
ob_start();
|
||||
$this =& $smarty; /* this should be done nicer, maybe */
|
||||
eval('?>' . $_var_compiled);
|
||||
$_contents = ob_get_contents();
|
||||
ob_end_clean();
|
||||
|
Reference in New Issue
Block a user