[wp-hackers] Re: Plugin to post source code needs testing

Viper007Bond viper at viper007bond.com
Tue Sep 11 23:45:54 GMT 2007


Yes, sadly the JS package requires invalid HTML and I don't know Javascript
well enough to modify it.

There's a ticket open on the matter as well:
http://code.google.com/p/syntaxhighlighter/issues/detail?id=25

On 9/11/07, Christian Höltje <docwhat+list.wp.hackers at gerf.org> wrote:
>
> * Otto (otto at ottodestruct.com) [070910 16:09]:
> > On 9/9/07, Viper007Bond <viper at viper007bond.com> wrote:
> > > As for GeSHi, that's server side. This plugin relies entirely on
> Javascript
> > > to do the highlighting and box. It makes it much easier to be honest,
> plus
> > > it works better for text readers.
> >
> > 1. How does it make it easier? I use WP-Syntax and just add wrappers
> > around my code that look like <pre lang="php">...</pre> and it just
> > works. I don't see that that is any easier to do than add [sourcecode]
> > wrappers. As far as implementation, you upload the plugin and activate
> > it. Can't get much simpler.
>
> I think he meant from a developer's point of view.  Also, I tried that
> plugin and I had problems.  I did like that the syntax let you disable
> the plugin and it looked "okay" in the browser...but this plugin has
> that potential as well...
>
> > 2. WP-Syntax generates completely valid XHTML and CSS for the code,
> > any text reader will read it just fine.
>
> The JavaScript SyntaxHighliter doesn't generate correct XHTML, so that
> *is* a problem.
>
> > 3. Using a server side system like GeSHi seems like a better solution
> > to me. For one thing, you don't have the page render the code first in
> > plain ugly black text and then suddenly have it jump to nice and
> > colored once the javascript kicks in.
>
> > I gotta say that while this is an interesting approach, the server
> > side approach is a better one which just makes more sense. So I'll
> > stick to WP-Syntax.
>
> I wouldn't mind the server side approach if it could be cached, but
> running GeSHi everytime gets expensive for anything more than small
> snippets.  And I do like the ability to server the unformatted
> version, etc.
>
> Ciao!
>
> --
> By the pricking of my thumbs, something wicked this way comes.
>         -- Shakespeare, MacBeth, IV:i
>
> The Doctor What: Not that 'who' guy.             http://docwhat.gerf.org/
> docwhat *at* gerf *dot* org                                        KF6VNC
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
>



-- 
Viper007Bond | http://www.viper007bond.com/


More information about the wp-hackers mailing list