• Resolved trejder

    (@trejder)


    This support thread suggests, that using Jetpack’s Markdown module with SyntaxHighlighter Evolved plugin is possible and recommended. However, I can’t get to to work, because Jetpack’s Markdown module seems to be forcing entities encoding and I don’t see any way to disable that.

    I have enabled Jetpack’s Markdown module and then installed SyntaxHighlighter Evolved plugin. I’m using it with nearly default set of configuration switches and in the simplest manner possible.

    So, for example, my entire post code (take from non-visual editor) looks like that):

    This is your **first post** and the example of *Markdown* and *code coloring* in the same time.

    Here is example of code snippet formatted using [SyntaxHighlighter Evolved](https://wordpress.org/plugins/syntaxhighlighter/) plugin:

    [php]$this->doThat();[/php]

    Correct me, if I’m doing something wrong.

    At this point, everything is fine. However, when I change part of syntax highlighted code to use some HTML entities:

    [php]<?php> echo $this->doThat(); ?>[/php]

    Then I’m getting something like this as a result:

    1 <?php> echo $this->doThat(); ?>

    Which is, of course, completely unusable.

    I tried various combinations of SyntaxHighlighter options. I noticed, that Markdown in Jetpack encodes entities, when trying to use any of SyntaxHighlighter provided shortcodes, so I even fallen back to using <pre></pre> instead. It looks fine (though not hightlighted), Markdown module does not tries to encode entities. But, when I enable Always load all language files (for directly using <pre> tags rather than shortcodes) option to colurize <pre> tags, everything goes hell again. So, at this point, I have no idea, which one of these two is responsible for making mess in my code snippets.

    What is the best approach to use Jetpack’s Markdown module with SyntaxHighlighter Evolved plugin together?

Viewing 1 replies (of 1 total)
  • Thread Starter trejder

    (@trejder)

    Damn, once again “hit” by stupid WordPress “preview” mechanism! 😐 Of course, everything is fine with both Jetpack’s Markdown module with SyntaxHighlighter Evolved plugin, once you hit Update button to finally update the post. All described problems happens only, when you’re using Preview Changes button.

Viewing 1 replies (of 1 total)
  • The topic ‘How to use Jetpack's Markdown module with SyntaxHighlighter Evolved’ is closed to new replies.