summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 63bf8c5)
raw | patch | inline | side by side (parent: 63bf8c5)
author | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 9 Feb 2009 10:54:30 +0000 (10:54 +0000) | ||
committer | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 9 Feb 2009 10:54:30 +0000 (10:54 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@13407 594d385d-05f5-0310-b6e9-bd551577e9d8
diff --git a/gosa-core/Changelog b/gosa-core/Changelog
index 444c3524291134815295b665f801348371d417f0..fa936effb83c0b5c21e7726c659672de6657bc9e 100644 (file)
--- a/gosa-core/Changelog
+++ b/gosa-core/Changelog
- Added missing existance checks for group mail addresses
- Fixed uid autogeneration which contained curly braces
- Moved essential schema files back to the core package
+ - Updated integrated smarty
* gosa 2.6.3
- Fixed several issues, occurred when using user templates
diff --git a/gosa-core/include/smarty/Config_File.class.php b/gosa-core/include/smarty/Config_File.class.php
index a10d30469d8975ac0c992afd2f957add103bb35d..31b89075077c560b73172db9c8b8d8d4dd20e4a6 100644 (file)
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
- * @link http://smarty.php.net/
- * @version 2.6.20
+ * For questions, help, comments, discussion, etc., please join the
+ * Smarty mailing list. Send a blank e-mail to
+ * smarty-discussion-subscribe@googlegroups.com
+ *
+ * @link http://www.smarty.net/
+ * @version 2.6.22
* @copyright Copyright: 2001-2005 New Digital Group, Inc.
* @author Andrei Zmievski <andrei@php.net>
* @access public
* @package Smarty
*/
-/* $Id: Config_File.class.php 2702 2007-03-08 19:11:22Z mohrt $ */
+/* $Id: Config_File.class.php 2786 2008-09-18 21:04:38Z Uwe.Tews $ */
/**
* Config file reading class
index 19318e6a17827929d0280e1cdd4c62937eed8e4a..95ec67bab8f459f3decb2b9da384b3a03c8ada5e 100644 (file)
*
* For questions, help, comments, discussion, etc., please join the
* Smarty mailing list. Send a blank e-mail to
- * smarty-general-subscribe@lists.php.net
+ * smarty-discussion-subscribe@googlegroups.com
*
- * @link http://smarty.php.net/
+ * @link http://www.smarty.net/
* @copyright 2001-2005 New Digital Group, Inc.
* @author Monte Ohrt <monte at ohrt dot com>
* @author Andrei Zmievski <andrei@php.net>
* @package Smarty
- * @version 2.6.20
+ * @version 2.6.22
*/
-/* $Id: Smarty.class.php 2722 2007-06-18 14:29:00Z danilo $ */
+/* $Id: Smarty.class.php 2785 2008-09-18 21:04:12Z Uwe.Tews $ */
/**
* DIR_SEP isn't used anymore, but third party apps might
*
* @var string
*/
- var $_version = '2.6.20';
+ var $_version = '2.6.22';
/**
* current template inclusion depth
diff --git a/gosa-core/include/smarty/Smarty_Compiler.class.php b/gosa-core/include/smarty/Smarty_Compiler.class.php
index f09f8de8dc6a0bbacde086324f362b57423d81e1..374ba3d0473feb22d0281c8bc18d124d52f004d2 100644 (file)
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
- * @link http://smarty.php.net/
+ * @link http://www.smarty.net/
* @author Monte Ohrt <monte at ohrt dot com>
* @author Andrei Zmievski <andrei@php.net>
- * @version 2.6.20
+ * @version 2.6.22
* @copyright 2001-2005 New Digital Group, Inc.
* @package Smarty
*/
-/* $Id: Smarty_Compiler.class.php 2773 2008-08-12 18:17:51Z Uwe.Tews $ */
+/* $Id: Smarty_Compiler.class.php 2966 2008-12-08 15:10:03Z monte.ohrt $ */
/**
* Template compiling class
var $_strip_depth = 0;
var $_additional_newline = "\n";
+
+ var $_phpversion = 0;
+
/**#@-*/
/**
*/
function Smarty_Compiler()
{
+ $this->_phpversion = substr(phpversion(),0,1);
+
// matches double quoted strings:
// "foobar"
// "foo\"bar"
// $foo->bar($foo->bar)
// $foo->bar($foo->bar())
// $foo->bar($foo->bar($blah,$foo,44,"foo",$foo[0].bar))
+ // $foo->getBar()->getFoo()
+ // $foo->getBar()->foo
$this->_obj_ext_regexp = '\->(?:\$?' . $this->_dvar_guts_regexp . ')';
$this->_obj_restricted_param_regexp = '(?:'
- . '(?:' . $this->_var_regexp . '|' . $this->_num_const_regexp . ')(?:' . $this->_obj_ext_regexp . '(?:\((?:(?:' . $this->_var_regexp . '|' . $this->_num_const_regexp . ')'
- . '(?:\s*,\s*(?:' . $this->_var_regexp . '|' . $this->_num_const_regexp . '))*)?\))?)*)';
- $this->_obj_single_param_regexp = '(?:\w+|' . $this->_obj_restricted_param_regexp . '(?:\s*,\s*(?:(?:\w+|'
+ . '(?:' . $this->_var_regexp . '|' . $this->_num_const_regexp . ')(?:' . $this->_obj_ext_regexp . '(?:\((?:(?:' . $this->_var_regexp . '|' . $this->_num_const_regexp . ')'
+ . '(?:\s*,\s*(?:' . $this->_var_regexp . '|' . $this->_num_const_regexp . '))*)?\))?)*)';
+
+ $this->_obj_single_param_regexp = '(?:\w+|' . $this->_obj_restricted_param_regexp . '(?:\s*,\s*(?:(?:\w+|'
. $this->_var_regexp . $this->_obj_restricted_param_regexp . ')))*)';
- $this->_obj_params_regexp = '\((?:' . $this->_obj_single_param_regexp
+
+ $this->_obj_params_regexp = '\((?:' . $this->_obj_single_param_regexp
. '(?:\s*,\s*' . $this->_obj_single_param_regexp . ')*)?\)';
- $this->_obj_start_regexp = '(?:' . $this->_dvar_regexp . '(?:' . $this->_obj_ext_regexp . ')+)';
- $this->_obj_call_regexp = '(?:' . $this->_obj_start_regexp . '(?:' . $this->_obj_params_regexp . ')?(?:' . $this->_dvar_math_regexp . '(?:' . $this->_num_const_regexp . '|' . $this->_dvar_math_var_regexp . ')*)?)';
+ $this->_obj_start_regexp = '(?:' . $this->_dvar_regexp . '(?:' . $this->_obj_ext_regexp . ')+)';
+ $this->_obj_call_regexp = '(?:' . $this->_obj_start_regexp . '(?:' . $this->_obj_params_regexp . ')?(?:' . $this->_dvar_math_regexp . '(?:' . $this->_num_const_regexp . '|' . $this->_dvar_math_var_regexp . ')*)?)';
// matches valid modifier syntax:
// |foo
}
// replace double quoted literal string with single quotes
$_return = preg_replace('~^"([\s\w]+)"$~',"'\\1'",$_return);
+ // escape dollar sign if not printing a var
+ $_return = preg_replace('~\$(\W)~',"\\\\\$\\1",$_return);
return $_return;
}
function _parse_var($var_expr)
{
$_has_math = false;
+ $_has_php4_method_chaining = false;
$_math_vars = preg_split('~('.$this->_dvar_math_regexp.'|'.$this->_qstr_regexp.')~', $var_expr, -1, PREG_SPLIT_DELIM_CAPTURE);
if(count($_math_vars) > 1) {
$_output .= '->{(($_var=$this->_tpl_vars[\''.substr($_index,3).'\']) && substr($_var,0,2)!=\'__\') ? $_var : $this->trigger_error("cannot access property \\"$_var\\"")}';
}
} else {
+ if ($this->_phpversion < 5) {
+ $_has_php4_method_chaining = true;
+ $_output .= "; \$_foo = \$_foo";
+ }
$_output .= $_index;
}
} elseif (substr($_index, 0, 1) == '(') {
}
}
- return $_output;
+ if ($_has_php4_method_chaining) {
+ $_tmp = str_replace("'","\'",'$_foo = '.$_output.'; return $_foo;');
+ return "eval('".$_tmp."')";
+ } else {
+ return $_output;
+ }
}
/**
diff --git a/gosa-core/include/smarty/internals/core.write_cache_file.php b/gosa-core/include/smarty/internals/core.write_cache_file.php
index 72f785b74ef07a0eea7ede689262409b246eccec..fa3cdd746d7342f055f269aa23dc4f40fb41fe4b 100644 (file)
if (!empty($smarty->cache_handler_func)) {
// use cache_handler function
call_user_func_array($smarty->cache_handler_func,
- array('write', &$smarty, &$params['results'], $params['tpl_file'], $params['cache_id'], $params['compile_id'], null));
+ array('write', &$smarty, &$params['results'], $params['tpl_file'], $params['cache_id'], $params['compile_id'], $smarty->_cache_info['expires']));
} else {
// use local cache file