1

Im wanting to use wordpress to share some code snips. However when viewing the posts some of the code tries to format even though its in pre or code tags. Is there anyone way to modify

    <?php the_content(); ?>

So that it will replace <, and > with the correct <, and > methods? I think this is my issue.

3
  • I normally share code snips just by typing the code inside the HTML editor within a "preformated" block, no problem at all (except if I have the spell checker from jetpack activated). When writing in HTML editor, < is stored as &lt; and > is stored as &gt; and the content between <pre> is not affected by the default content filters of Wordpress.
    – cybmeta
    Commented Sep 27, 2013 at 9:36
  • I am unable to do this which is why i am not and ask how to do it through the_content to work with what i need. And actually yes even the HTML form still formats the content. Just a different aspect. Commented Sep 27, 2013 at 9:40
  • Are you talking about aspect? So, you can dipslay the code snip but you don't like the aspect? I don't get you.
    – cybmeta
    Commented Sep 27, 2013 at 9:43

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.