WordPress.org

Ready to get started?Download WordPress

Forums

How to temporarily disable Markdown? (3 posts)

  1. TinyClanger
    Member
    Posted 9 years ago #

    I'm trying to embed some Google Maps Javascript code in a page. Unfortunately, Markdown leaves all the code alone, except for the line //]]>, which gets translated into //]]&gt;, causing Google Maps to fall over and die. I'd really love to be able to surround the code in some sort of <nomarkdown> tags, which would disable Markdown and leave the code entirely unmolested.

    Does anybody know of a way to do this? (It would be nice if Markdown would take \> as 'just put a > without mucking around', of course... :)

    Turning Markdown off entirely isn't an option - the other contributors to the site aren't going to want to muck about with HTML.

    Thanks

  2. MichelFortin
    Member
    Posted 9 years ago #

    I've checked this on the PHP Markdown Dingus:

    <script><[CDATA[ test() // ]]></script>

    And Markdown doesn't change anything. Are you sure Markdown is the problem? Are you using the latest version (1.0.1b)? It could also be another WordPress filter down in the chain in which case the problem would still be visible when deactivating Markdown.

  3. TinyClanger
    Member
    Posted 9 years ago #

    OK, that was odd. I tested my original script on the Dingus (which I didn't know about until now - thanks for the link!) and it changed that >. Tried your test case, no problem. Cut and pasted bits of my code back in, and still no problem.

    I don't know what caused that, but I now have Google Maps working. Thanks!

Topic Closed

This topic has been closed to new replies.

About this Topic