javascript in posts with quotes
-
I’m trying to call a javascript function from within a post. I have read Using Javascript, and the method described there works fine if you’re just calling a function by itself, but it breaks if you need to pass parameters to the function like this:
afunction('value')
— wordpress adds backslashes before the two single quotes. Is there any way to keep wordpress from doing this?Lorelle mentioned using stripslashes() in the article above, and I tried wrapping that function around my call to the_content() but the slashes were still appended.
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘javascript in posts with quotes’ is closed to new replies.