[Radiant] Syntax Highlighting
Sean Cribbs
seancribbs at gmail.com
Tue Jul 15 09:01:57 CDT 2008
It's not perfect, but I like using Dan Webb's Syntax Highlighter
(JavaScript). Just put your source code inside <code> tags with the
class of the language you want, like so:
<code class="ruby">puts "Hello, World!"</code>
You can download it at http://danwebb.net.
Sean
Josh Schairbaum wrote:
> Is anyone using the syntax_highlighting extension?
> http://github.com/marcoow/syntax_highlighting/tree/master
>
> It seems to be doing the parsing, but when it renders in a page, it's
> strictly as "code" html, so all the <span> tags that input as part of
> it are rendered as well.
>
> For example,
>
> <r:code language="python">
> import pygments
> foo = "bar"
> </r:code>
>
> renders as:
>
> <span class="k">import</span> <span class="nn">pygments</span> <span
> class="n">foo</span> <span class="o">=</span> <span
> class="n">"bar"</span>
>
> Any ideas? There is currently no filter set on the page, and if I set
> it to "textile" all the < & > get turned to < & >, respectively.
>
> Is there another option for syntax highlighting? I would like to have
> more languages than code_ray currently supports.
> _______________________________________________
> Radiant mailing list
> Post: Radiant at radiantcms.org
> Search: http://radiantcms.org/mailing-list/search/
> Site: http://lists.radiantcms.org/mailman/listinfo/radiant
>
More information about the Radiant
mailing list