unknownhost
11-07-2002, 05:05 PM
Hey guys - I have a php form that submits to a mysql database and there's one last bug - when someone uses the "\" character it errors out. How do I make it treat "\" as part of the string without interrupting the statement or how do I strip the \ from the input:
example code:
$sql = "INSERT INTO affiliates SET " .
"pridomain='$pridomain', " .
"uname='$uname', " .
"upwd='$upwd', " .
error when \ is used:
Error adding your registration entry: You have an error in your SQL syntax near '\'
_________________
The Unknown Host
I Gotta Get A NOC
example code:
$sql = "INSERT INTO affiliates SET " .
"pridomain='$pridomain', " .
"uname='$uname', " .
"upwd='$upwd', " .
error when \ is used:
Error adding your registration entry: You have an error in your SQL syntax near '\'
_________________
The Unknown Host
I Gotta Get A NOC
