WordPress: Text being changed

Quotations and dashed are different from the original text to the display. This is problematic is you’re using code, because it will change it. 

This is called wptexturize. 

To solve this add the following code on the functions.php file inside the template folder.

add_filter( ‘run_wptexturize’, ‘__return_false’ );



Quoting this great answer: 

Plugins will be able to re-enable any filter you have switched off, if they do so after you are finished. So the trick is to make sure you are the last one to do something with this filter by setting a high number, low priority on it.

add_filter( 'run_wptexturize', '__return_false', 9999 );

Leave a Reply

Your email address will not be published. Required fields are marked *