July 28, 200917 yr Hi All i would like to use real escape string for data that is been inserted into mysql database but there could be 50 plus fields in the database is there a function that can be used to do this thanks again
July 28, 200917 yr Surely you want to do the escaping BEFORE inserting it into the DB? You could get all the values as an array. For example, if the values had been sent via a forum using POST: $data = ($_POST['field1'], $_POST['field2']); $escapedData = new Array(); foreach($data as $d) { $escapedData[] = mysql_escape_string($d); } Something along those lines?
Create an account or sign in to comment