Hi All,
What would be the best way to save XML to a database?
I mean I can use the example
'http://www.php.net/manual/en/function.mysql-real-escape-string.php'.
they give a function to prevent any SQL Injection,
function quote_smart($value)
{
// Stripslashes
if (get_magic_quotes_gpc()) {
$value = stripslashes($value);
}
// Quote if not integer
if (!is_numeric($value)) {
$value = "'" . mysql_real_escape_string($value) . "'";
}
return $value;
}
but then how do I get the data back, (as intended), from the db?
what would be the reverse of the above code?
Many thanks
Simon