Support » Plugin: Simple Code Highlighter » Console Errors Prettify.css

  • Not sure why, but just recently the plugin gives console errors on all pages of my website about a prettify.css file.

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

Viewing 5 replies - 1 through 5 (of 5 total)
  • Experiencing the same issue here. Is there any way to either resolve this or make sure that pretty.css only attempts to load on pages that actually use the highlighter?

    I just went into plugins/simple-code-highlighter/js/pretty.js and hardcoded the URL into it, tbh. Easy enough fix until the plugin dev updates it.

    @tecca

    I agree, I just removed the following line from the pretty.js file:

    A.push("loader/prettify.css');

    Hopefully this gets fixed soon. Optionally, if you want to use it, you can just change that to a hard url for your site like:

    A.push("https://www.mysite.com/wp-content/plugins/simple-code-highlighter/js/loader/prettify.css");

    Although, it actually looked worse since there was no padding around the code.

    https://www.antigopc.com/resize-ubuntu-partitions/

    Thread Starter Prodjex

    (@prodjex)

    I don’t think the author supports it any longer, it’s been a couple month already.

    Thanks for the fix though, just applied an the error is gone now. Also a great suggestion on the padding.

    I have some strings that run long in my code that extend out of the frame. Anyone else had this issue? If so curious as to how others dealt with it. Word break css is all I can think of.

    Example here: https://www.prodjex.com/2018/02/jquery-select-drop-change-event/

    I had this issue too, and traced it back to another plugin – Autoptimize. I disabled javascript optimization, and the prettify.css file loaded.

    So, if you’re using a service like Autoptimize, either disable javascript entirely, or exclude the specific file: “wp-content/plugins/simple-code-highlighter/js/pretty.js”

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Console Errors Prettify.css’ is closed to new replies.