This question about Using an extension: Answered

How to get nicely formatted verbatim blocks?

I've seen in some questions that verbatim blocks are rendered very nicely (see below example). I've seen in the raw mode that at least two things are needed:
  1. JQueryPlugin and something called chili.
  2. adding the class="tml" to the verbatim tag.
  1. What do I actually need to install on my site to use this?
    --> JQueryPlugin, of course. But does this contain the chili code as well, or where do I get that?
  2. What other styles besides TML does it support; can it do SQL?
Sample: This block is formatted using %JQREQUIRE{"chili"}%<verbatim class="tml"> :
  header="| *Topic* | *Last updated* | *By* |"
  format="| [[%BASEWEB%.$topic][$topic]] | $date | $wikiname |"


Yes, it can do SQL.

On a 1.1.x Foswiki you don't need to install anything, since the jQuery Javascript library for Foswiki is part of the default Plugins. Since you claim to be using Foswiki 1.1.2, you shouldn't have to install anything. I changed the type of question from "Using an extension" to "Using an extension", since this extension is already part of your installation.

Chili is the jQuery code highlighter plugin. It is provided in Foswiki's JQueryPlugin


All the currently supported class attributes are mentioned there, and can be seen in System.JQueryChili once the plugin is installed:

Available class attributes:
cplusplus C++
csharp C#
css Cascading Style Sheets
bash shell syntax
delphi Delphi
html Hypertext Markup Language
java Java
js JavaScript
lotusscript LotusScript
php-f Hypertext Preprocessor -f
php Hypertext Preprocessor
sql Structured Query Language
tml Wiki Markup Language

-- RaulFRodriguez - 11 Jan 2011

QuestionForm edit

Subject Using an extension
Extension JQueryPlugin
Version Foswiki 1.1.2
Status Answered
Topic revision: r2 - 11 Jan 2011, RaulFRodriguez
The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. See Copyright Statement. Creative Commons License    Legal Imprint    Privacy Policy