Umm, how about using str_replace to replace the quotes for there ASCII
and when you print them out in HTML they will be interpreted properly,
or you
could str_replace them back.

On Thu, 2003-03-20 at 11:23, Poon, Kelvin (Infomart) wrote:

    Actually, that eliminated the error messages but it still hasn't fix
    I did what you said....but now in my MSSQL table, the content column
    somethign like thsi
    "Step 1: blah blah balh
    Step 2: blah balh balh \'Username\'"
    so it included the slashes...I just learned that mSSQL doens;t
    slashes so is there any other way I can fix this problem?..I want
    step 1: balh bah balh
    Step 2: balhb alhb alhb 'Username'
    to be inserted to the table..please help 
    thanks a lot by the way
    -----Original Message-----
    From: CPT John W. Holmes [mailto:[EMAIL PROTECTED]
    Sent: Thursday, March 20, 2003 11:06 AM
    To: Poon, Kelvin (Infomart); [EMAIL PROTECTED]
    Subject: Re: [PHP-DB] Addslashes (MSSQL)
    > where my $content value is osmethign like this.
    > "Step 1: Access the homepage
    > Step 2: type in your username under the field 'username' "
    > and after the addslashes funciton there would be \ around the
    > like this..
    > \'username\'....and now after running this program I got an error
    > Warning: MS SQL message: Line 14: Incorrect syntax near
    > (severity 15) in
    > on line 119
    I think you need to replace ' with '' in MSSQL (one single quote
    with two single quotes)
    $text = str_replace("'","''",$old_text);
    ---John Holmes...
    PHP Database Mailing List (
    To unsubscribe, visit:
    PHP Database Mailing List (
    To unsubscribe, visit:

The Cryptocomm Group
My GPG Key:

Reply via email to