I just preg_replace("/\'/","\'",$text) and all was good :o)
"David Robley" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > In article <[EMAIL PROTECTED]>, > [EMAIL PROTECTED] says... > > I am using PHP and MySQL on a 2k dev box to be uploaded to a linux box > > > > I have a piece of SQL > > > > INSERT INTO `contracts` (`key`, `content`) VALUES (1,'blah blah blah > > character 39 is a single speach mark '+CHAR(39)+' blah blah blah') > > > > Instead of inserting: 'blah blah blah character 39 is a single speach mark ' > > blah blah blah > > It inserts 0 > > All variations work fine when there is no single speachies > > > > help? > > Look into addslashes and the various magic_quotes settings in you r > php.ini. > > > -- > David Robley > Temporary Kiwi! > > Quod subigo farinam -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php