diff options
| author | monte.ohrt <monte.ohrt@localhost> | 2010-06-08 20:45:18 +0000 |
|---|---|---|
| committer | monte.ohrt <monte.ohrt@localhost> | 2010-06-08 20:45:18 +0000 |
| commit | c963a8342e8ba8693c8a5d61d496cfb56045d1c6 (patch) | |
| tree | 50f6cd82a4493e665ddabbca8bd0731f3391e609 /libs/sysplugins/smarty_internal_data.php | |
| parent | cf2f6a33e1a9fc02452bfdd71f5e965327d4eab5 (diff) | |
| download | smarty-c963a8342e8ba8693c8a5d61d496cfb56045d1c6.tar.gz smarty-c963a8342e8ba8693c8a5d61d496cfb56045d1c6.tar.bz2 smarty-c963a8342e8ba8693c8a5d61d496cfb56045d1c6.zip | |
fix assign_by_ref and append_by_ref BC compatability
Diffstat (limited to 'libs/sysplugins/smarty_internal_data.php')
| -rw-r--r-- | libs/sysplugins/smarty_internal_data.php | 28 |
1 files changed, 26 insertions, 2 deletions
diff --git a/libs/sysplugins/smarty_internal_data.php b/libs/sysplugins/smarty_internal_data.php index 6813ad6c..ec7d0d4f 100644 --- a/libs/sysplugins/smarty_internal_data.php +++ b/libs/sysplugins/smarty_internal_data.php @@ -68,6 +68,19 @@ class Smarty_Internal_Data { } } /** + * wrapper function for Smarty 2 BC + * + * @param string $tpl_var the template variable name + * @param mixed $ &$value the referenced value to assign + * @param boolean $nocache if true any output of this variable will be not cached + * @param boolean $scope the scope the variable will have (local,parent or root) + */ + public function assign_by_ref($tpl_var, &$value, $nocache = false, $scope = SMARTY_LOCAL_SCOPE) + { + trigger_error("function call 'assign_by_ref' is unknown or deprecated, use 'assignByRef'",E_USER_NOTICE); + $this->assignByRef($tpl_var,$value,$nocache,$scope); + } + /** * appends values to template variables * * @param array $ |string $tpl_var the template variable name(s) @@ -157,7 +170,18 @@ class Smarty_Internal_Data { } } } - + /** + * wrapper function for Smarty 2 BC + * + * @param string $tpl_var the template variable name + * @param mixed $ &$value the referenced value to append + * @param boolean $merge flag if array elements shall be merged + */ + public function append_by_ref($tpl_var, &$value, $merge = false) + { + trigger_error("function call 'append_by_ref' is unknown or deprecated, use 'appendByRef'",E_USER_NOTICE); + $this->appendByRef($tpl_var,$value,$merge); + } /** * Returns a single or all template variables * @@ -440,4 +464,4 @@ class Undefined_Smarty_Variable { } } -?>
\ No newline at end of file +?> |
