Code Display
This plugin has officially been killed as there are much better plugins out there.
Here’s a list of some of them: http://codex.wordpress.org/Plugins/Syntax_Highlighting
Code DisplayThis plugin has officially been killed as there are much better plugins out there.
Here’s a list of some of them: http://codex.wordpress.org/Plugins/Syntax_Highlighting
Post at WordPress Station
Post at Blogging Pro China
Post at Priyadi’s Place
Great idea :) I saw the comments in the code about regex and wrote a PCRE version of it.
Nice work. That’s a hell of a lot cleaner. :) Not sure if it’s faster or not though. I’ve been told regex is actually fairly slow and using substr and such may be quicker. But regardless, again, it’s way cleaner. :D
I just realized that if you use non-allowed tags inbetween
tags, such asThere is however a plugin that fixes this. Rather than just recommend that that plugin be run alongside mine, I’m just going to combine the two and make life easier all around. Stay tuned.
Oh, and thanks to Ozh for pointing this out.
Actually, it seems that plugin is just a more sophisticated version of my plugin.
The non-allowed HTML tags are stripped out BEFORE they are inserted into the database, so unless WordPress changes this, some code file editing or making this comment form post to a seperate file.
However, now that I think of it, that actually may work quite well. Just clone
wp-comments-post.phpand have this plugin process on the comment content before it’s inserted into the database.Ooo, I like it. Off to code that or something like it. :)
I typed this in exactly as it appears:
Ah, some improvements here :)
How is this one doing then ?
< ?php echo "“; ?>
Indeed, works fine :)
Now you “just” have to make it compatible with the comment Live Preview so that code displays properly right when typing it ;)
Shouldn’t be hard to do, but I tired editing Live Comment Preview and I couldn’t get it to work right. :(
New version - v2.01. Code Display was operating on the feeds and that’s a no-no as it creates invalid code. All better now (hopefully).
This plugin is no longer under development. Hell, version 2 of it was just mostly the code from another plugin.
Check out this plugin for a much better replacement.