mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-22 23:00:56 +01:00
stripslashes on the first level of a posted array, per discussion with lars
This commit is contained in:
parent
4137e48c3e
commit
e0e5763821
@ -510,9 +510,21 @@
|
||||
$value = $GLOBALS[$meth][$varname];
|
||||
$i = $cnt+1;
|
||||
}
|
||||
if(get_magic_quotes_gpc() && !@is_array($value))
|
||||
if(get_magic_quotes_gpc())
|
||||
{
|
||||
$value = stripslashes($value);
|
||||
if(@is_array($value))
|
||||
{
|
||||
/* stripslashes on the first level of array values */
|
||||
foreach($value as $name => $val)
|
||||
{
|
||||
$value[$name] = stripslashes($val);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
/* stripslashes on this (string) */
|
||||
$value = stripslashes($value);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 'FILES':
|
||||
|
Loading…
Reference in New Issue
Block a user