]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
strip slashes
authorEvan Prodromou <evan@prodromou.name>
Thu, 22 May 2008 10:36:30 +0000 (06:36 -0400)
committerEvan Prodromou <evan@prodromou.name>
Thu, 22 May 2008 10:36:30 +0000 (06:36 -0400)
Check if automated slash-adder is on, and if so, strip out automated
slashes.

darcs-hash:20080522103630-84dde-4f6d10b6e6efff91a53c4af735040995ae947211.gz

lib/action.php

index 9b7988a190e031bf69c449f6808dfd08b076c967..c346c751313482206230f1d016a7379bfdc62005 100644 (file)
@@ -40,9 +40,10 @@ class Action { // lawsuit
        }
        
        function handle($argarray) {
+               $strip = get_magic_quotes_gpc();
                $this->args = array();
                foreach ($argarray as $k => $v) {
-                       $this->args[$k] = $v;
+                       $this->args[$k] = ($strip) ? stripslashes($v) : $v;
                }
        }
 }