jQuery escaping and I don't want it to

JavaScript and client side scripting.

Moderator: General Moderators

Post Reply
Cirdan
Forum Contributor
Posts: 144
Joined: Sat Nov 01, 2008 3:20 pm

jQuery escaping and I don't want it to

Post by Cirdan »

I'm trying to do inline editing for my website using jQuery so I can edit the HTML and text of a page without having to change the source. When I submit the form data though jQuery's $.ajax function, it escapes all the quotes. How can I either prevent jQuery from escaping this(probably a bad idea) or remove them on the PHP side of things. I tired stripslashes...but that didn't do anything. I know it's jQuery because if I do htmlentities() before submitting the text to MySQL...the slashes are still added.
User avatar
kaszu
Forum Regular
Posts: 749
Joined: Wed Jul 19, 2006 7:29 am

Re: jQuery escaping and I don't want it to

Post by kaszu »

It's not jQuery, it's PHP. jQuery doesn't do any escaping.
See magic quotes. stripslashes should work, not sure why it didn't work for you.
This topic should be moved to PHP section.
Cirdan
Forum Contributor
Posts: 144
Joined: Sat Nov 01, 2008 3:20 pm

Re: jQuery escaping and I don't want it to

Post by Cirdan »

Ah crap. Could have sworn those were off. Thanks
Post Reply