• Resolved kikib

    (@kikib)


    I picked “Okaidia” theme from Prism.js. However, the dark background isn’t showing in the single post. I cannot think of any reasons and I need to ask some questions.

    Does this work for Custom Post Types? This link for blog is Custom Post Type. But I thought I fixed it by unchecking Limit to Posts in the Settings.

    Did I add the wrong code? I followed your instructions by wrapping up single line with </code> and multiply line with <pre><code></pre></code>

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Jeff Starr

    (@specialk)

    For syntax highlighting, you also need to add the language attribute as explained in the instructions. Otherwise, the scripts do not recognize the code block.

    Or if you just want to do code escaping without highlighting, then using <pre><code></pre></code> without any language attribute works fine.

    For CPTs, they should be supported.. the best way to test is to try syntax highlighting on a regular WP Post (making sure to include the proper language attribute), and see if it works. If not, then there is something (like another plugin or maybe the theme) that is interfering with normal functionality.

    Thread Starter kikib

    (@kikib)

    Thanks! I just added the class=”language-html” and so on to each code.

    Plugin Author Jeff Starr

    (@specialk)

    Awesome, glad you got it.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Couldn’t get Prism version to work’ is closed to new replies.