I was searching for such a plugin, since my blog mostly revolves around programming. Since it's bilingual, I was looking for a way to write each snippet only once, so that each article could share it with its translation. This plugin did the trick!
The ability to execute snippets came as a bonus. This article executes the very same code it displays. Smooth!
Rendering needs some improvement, IMHO, but that's rather minor.
Keep up the good work!
Just installed this for my latest post where I had to show off more code than usual and it works just like expected. You can create new snippets and easily reference them in your posts using the shortcode listed in the Code Snippets screen. Neat!
I only have two small nitpicks:
1. There was some CSS bleed which caused the box to be way too high. It seems as if each line is always 18px tall but the line height is not enforced. I fixed it by adding line-height: 18px; to .ace_editor.
2. Since I added the snippet through the Code Snippets editor I was first confused about how to actually reference the snippet in the post. Turns out _there is_ a way to add/insert snippets from the editor, but it's only visible in the Visual editor. Since you're inserting content in my mind it would make more sense if it was simply a button right next to the Upload Media button above the editor altogether.
You must log in to submit a review. You can also log in or register using the form near the top of this page.