backslash apostrophe bug
-
I realize this bug has been discussed and troubleshooted many years ago… believe it or not I’m getting this issue right now.
Most of the time, not quite sure if it’s all the time, when a user posts in activity feed, every apostrophe is preceded by a backslash. For example, It’s becomes It\’s
When as admin I edit their comment, it does not show the backslash and when saved it does not show. But on page refresh it shows it again. Can only seem to remove it by editing database directly and removing the backslash from the content.
Not sure but I just seemed to notice that a new comment less than maybe about 24 hours seems to display okay. But then after about 24 hours, that same comment now displays backslashes with the apostrophes.
I’ve disabled magic_quotes_gpc, magic_quotes_sybase, magic_quotes_runtime.
I’m now re-trying out the following code just in case I gave up on it too soon.
//Attempt to strip backslashes add_filter( 'get_topic_title', 'strip_the_title_slashes', 20, 2); function strip_the_title_slashes( $title, $id ) { return stripslashes( $title ); } add_filter( 'get_post_text', 'strip_the_text_slashes', 20, 2); function strip_the_text_slashes( $text, $id ) { return stripslashes( $text ); }
Any other suggestions, please?
- You must be logged in to reply to this topic.