irwan

basic for anti inject

Nov 15th, 2011
120
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.19 KB | None | 0 0
  1. function cleanuserinput($dirty){
  2. if (get_magic_quotes_gpc()) {
  3. $clean = mysql_real_escape_string(stripslashes($dirty));
  4. }else{
  5. $clean = mysql_real_escape_string($dirty);
  6. }
  7. return $clean;
  8. }
  9.  
Advertisement
Add Comment
Please, Sign In to add comment