mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-22 06:30:59 +01:00
using global array_stripslashes function
This commit is contained in:
parent
1587c977b8
commit
d140da563c
@ -2188,18 +2188,11 @@ class etemplate extends boetemplate
|
||||
*
|
||||
* @param array &$var
|
||||
* @return array
|
||||
* @deprecated use global array_stripslashes
|
||||
*/
|
||||
static function array_stripslashes($var)
|
||||
{
|
||||
if (!is_array($var))
|
||||
{
|
||||
return stripslashes($var);
|
||||
}
|
||||
foreach($var as $key => $val)
|
||||
{
|
||||
$var[$key] = is_array($val) ? self::array_stripslashes($val) : stripslashes($val);
|
||||
}
|
||||
return $var;
|
||||
return array_stripslashes($var);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -2229,7 +2222,7 @@ class etemplate extends boetemplate
|
||||
$content = array();
|
||||
if (get_magic_quotes_gpc())
|
||||
{
|
||||
$content_in = self::array_stripslashes($content_in);
|
||||
$content_in = array_stripslashes($content_in);
|
||||
}
|
||||
self::$validation_errors = array();
|
||||
$this->canceled = $this->button_pressed = False;
|
||||
|
@ -2374,29 +2374,6 @@ class infolog_ui
|
||||
return $icon ? Api\Html::image('infolog',$icon,lang($alt),'border=0') : lang($alt);
|
||||
}
|
||||
|
||||
/**
|
||||
* stripping slashes from an array
|
||||
*
|
||||
* @static
|
||||
* @param array $arr
|
||||
* @return array
|
||||
*/
|
||||
function array_stripslashes($arr)
|
||||
{
|
||||
foreach($arr as $key => $val)
|
||||
{
|
||||
if (is_array($val))
|
||||
{
|
||||
$arr[$key] = self::array_stripslashes($val);
|
||||
}
|
||||
else
|
||||
{
|
||||
$arr[$key] = stripslashes($val);
|
||||
}
|
||||
}
|
||||
return $arr;
|
||||
}
|
||||
|
||||
/**
|
||||
* Infolog's site configuration
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user