The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

mysql automaticly adds \'

Discussion in 'General Discussion' started by johnburk, Sep 17, 2009.

  1. johnburk

    johnburk Well-Known Member

    Joined:
    Jun 23, 2006
    Messages:
    241
    Likes Received:
    0
    Trophy Points:
    16
    Perhaps this is more a coding or mysql problem than a cpanel problem, but I am not sure.

    Since the upgrade of mysql in cpanel. Sentences with ' are changed to \' in the database. When I manually change them back, they are automaticly changed into \' again.


    The input type is varchar(255) and it is latin1_swedish_ci.

    Does anyone know how this can be fixed?
     
  2. Data 1

    Data 1 Well-Known Member

    Joined:
    May 25, 2008
    Messages:
    113
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Columbus Ohio
    cPanel Access Level:
    DataCenter Provider
    This perhaps explains it better than I can. What you are seeing is proper. If you want to echo it properly after extracting it you can use the "stripslashes" call in php.


    PHP Tutorials: PHP and Escaping
     
  3. johnburk

    johnburk Well-Known Member

    Joined:
    Jun 23, 2006
    Messages:
    241
    Likes Received:
    0
    Trophy Points:
    16
    Thank you Data 1

    My problem is that it appears after people fill in a text field simular to this response box yet here. Jonh's car is displayed propally.
     
    #3 johnburk, Sep 17, 2009
    Last edited: Sep 17, 2009
Loading...

Share This Page