Project

General

Profile

Bug #19182 » bug0009100_correct_updated.diff

Administrator Admin, 2008-08-15 14:00

View differences:

t3lib/class.t3lib_div.php (working copy)
* @return mixed POST var named $var and if not set, the GET var of the same name.
* @see GPvar()
*/
public static function _GP($var) {
if(empty($var)) return;
$value = isset($_POST[$var]) ? $_POST[$var] : $_GET[$var];
if (isset($value)) {
if (is_array($value)) { t3lib_div::stripSlashesOnArray($value); } else { $value = stripslashes($value); }
}
return $value;
public static function _GP($var) {
if(empty($var)) return;
$value = t3lib_div::array_merge_recursive_overrule((array)$_GET[$var],(array)$_POST[$var]);
if(!count($value)) unset($value); else $value = current($value);
if (isset($value)) {
if (is_array($value)) {
t3lib_div::stripSlashesOnArray($value);
}
else {
$value = stripslashes($value);
}
}
return $value;
}
/**
(3-3/4)