WordPress.org

Ready to get started?Download WordPress

Forums

Crayon Syntax Highlighter
[resolved] Unable to save post - get 404 errors (8 posts)

  1. steve49589
    Member
    Posted 2 years ago #

    Hello,
    I'm trying out your plugin, and for some reason whenever I try to save the post or publish the post, I am redirected to my site's 404 page not found.

    Any suggestions?

    I'm using a theme from StudioPress with the Genesis framework.

    http://wordpress.org/extend/plugins/crayon-syntax-highlighter/

  2. steve49589
    Member
    Posted 2 years ago #

    Actually, some of my code snippets will go in, but others will not.

    This will not work ... add it and I get a 404 error.

    [crayon lang="js"]<div id="fb-root"></div>
    <script>(function(d, s, id) {
      var js, fjs = d.getElementsByTagName(s)[0];
      if (d.getElementById(id)) return;
      js = d.createElement(s); js.id = id;
      js.src = "//connect.facebook.net/en_US/all.js#xfbml=1&appId=YOURFACEBOOKAPPID";
      fjs.parentNode.insertBefore(js, fjs);
    }(document, 'script', 'facebook-jssdk'));</script>[/crayon]

    Also, is there a way to wrap the lines? Can't figure that out...

    Thanks

  3. steve49589
    Member
    Posted 2 years ago #

    Here is a text file with the full post I'm trying to save or publish. Tried in a basic site and deactivating all plugins - still no joy.

    It must be the way I'm adding the shortcode?

  4. akarmenia
    Member
    Plugin Author

    Posted 2 years ago #

    Thanks for that, sorry I didn't see this sooner. I'll need to see if there's an email notification for newly added topics... There sure is a better way now! Use the tag editor button (<>) in the visual editor, or the "crayon" button in the HTML editor. I prefer using the visual editor now, since this integrates nicely and you can even type. When you select a pre tag (which is what it creates Crayons as) it will highlight blue and you can edit the code and settings in tag editor - the same window that you use to create Crayons. You can even switch between HTML and Visual modes and it should all just work.

    http://dl.dropbox.com/u/33811812/Crayon/crayon-syntax-highlighter-1.9.0-5.zip

  5. akarmenia
    Member
    Plugin Author

    Posted 2 years ago #

    Oh, and with the tag editor this won't apply since < is encoded to & lt; but if you use plugins that let you put PHP code into posts, then the code in the Crayon may turn into PHP code and cause issues. I had an issue with PHP Exec like this, but like I said with the Tag Editor it won't apply.

  6. akarmenia
    Member
    Plugin Author

    Posted 2 years ago #

    Also, that post text works fine for me:

    http://dl.dropbox.com/u/33811812/Crayon/support/forum1.png

    And if you have HTML and PHP in the same document and want to highlight both, then set the language to html to allow the bits between PHP tag to be rendered as html and bits inside php tags to be php.

  7. steve49589
    Member
    Posted 2 years ago #

    akarmenia: This is the issue that I discussed with you via email and it is now resolved.

    It was a server setting issue in ModSec ... not allowing this to work. The server config was changed to allow this by my host.

  8. akarmenia
    Member
    Plugin Author

    Posted 2 years ago #

    Oh right, sorry Steve I didn't recognise your username :)

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic