Posted by noone on 02/04/06 20:27
monomaniac21 wrote:
> Is there a function that allows you to add a \ before a ' in a string.
> This is needed to store text in a mysql db and i was wondering if there
> is function which can do this to any ' which DO NOT already have one
> before them, this is so i can keep editing my text without all these \
> building up.
>
> Kind regards
>
> Marc
>
I just include it in the insert statement since you must know the
datatype at insert time
$sqli = "insert into tableA values ";
$sqli .= "('".$_POST['varchar']."',".$_POST['integer']")";
Michael Austin
DBA.
[Back to original message]
|