From: Florian G. <re...@us...> - 2010-09-16 12:04:23
|
Update of /cvsroot/perfparse/_perfparse-phpgui In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv9205/phpgui Modified Files: perfparse.php Log Message: Fixed handling of special characters in metric names (Christian Vieser) Index: perfparse.php =================================================================== RCS file: /cvsroot/perfparse/_perfparse-phpgui/perfparse.php,v retrieving revision 1.67 retrieving revision 1.68 diff -C2 -d -r1.67 -r1.68 *** perfparse.php 30 Dec 2008 21:55:44 -0000 1.67 --- perfparse.php 16 Sep 2010 12:04:16 -0000 1.68 *************** *** 22,26 **** // todo: magic quotes also changes the indexes in request arrays ! } // setup section --- 22,45 ---- // todo: magic quotes also changes the indexes in request arrays ! //keys escapen ! function undoMagicQuotes($array, $topLevel=true) { ! $newArray = array(); ! foreach($array as $key => $value) { ! $key = stripslashes($key); ! if (is_array($value)) { ! $newArray[$key] = undoMagicQuotes($value, false); ! } ! else { ! $newArray[$key] = $value; ! } ! } ! return $newArray; ! } ! ! ! $_POST = undoMagicQuotes($_POST); ! $_REQUEST = undoMagicQuotes($_REQUEST); ! ! } //endif // setup section |