Simple php mysql injection detect


/ Published in: Other
Save to your folder(s)



Copy this code and paste it in your HTML
  1. unction 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.  

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.