Modifying my WP-SynHighlight addon for WordPress I came across a problem, that WordPress rewrites symbols inside my codesyntax shortcode with their nicer Unicode equivalents. I patched code against some. Then against some more. And then some more… And at last I felt tired of patching my code. Suddenly, I came across no_texturize_shortcodes filter, documentation for which at the time of written was published nowhere.
It’s a simple filter, that is used to temporarily turn off Unicode conversion of symbols. It’s very easy to use it:
function fr_no_texturize_shortcodes($shortcodes_arr) {
$shortcodes_arr[] = 'codesyntax';
return $shortcodes_arr;
}
add_filter('no_texturize_shortcodes', 'fr_no_texturize_shortcodes');So, by using this, all text inside provided shortcode tag (codesyntax) will not be converted.




