Daney11 Posted December 7, 2007 Share Posted December 7, 2007 // Start String Function function escape_data($data) { global $connect; if (ini_get('magic_quotes_gpc')) { $data = stripslashes($data); } return mysql_real_escape_string(trim($data), $connect); } // End String Function I have this function and i use escape_data($blah); etc.. Would this be the best function to use or would anyone do anything a little bit different? For security, i.e SQL Injections. Thanks Link to comment https://forums.phpfreaks.com/topic/80690-this-function/ Share on other sites More sharing options...
Yesideez Posted December 7, 2007 Share Posted December 7, 2007 Have a read of this topic: http://www.phpfreaks.com/forums/index.php/topic,170844.0.html Link to comment https://forums.phpfreaks.com/topic/80690-this-function/#findComment-409240 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.