Loading...
 
Skip to main content

History: PluginCode

Preview of version: 12 (current)

Code Wiki Plugin

Code can be used to display lines of preformatted code in wiki pages.

Using CODE tag

Without parameters

{CODE()} <?php function foo($foo) { print($foo); }?> {CODE}
Copy to clipboard
<?php function foo($foo) { print($foo); }?>

Line numbering : ln

{CODE(ln=>1)}some code line numbered {CODE}
Copy to clipboard
some code line numbered

(1.8) Syntax coloring : colors

Only php color is available for now. more are expected.

{CODE(colors=>php)}<?php function foo($foo) { print($foo); }?>{CODE}
Copy to clipboard
<?php function foo($foo) { print($foo); }?>

(1.9) caption insert : caption

{CODE(caption=>Caption)}some text{CODE}
Copy to clipboard
some text


(1.7.1.1) If you see confusing output like "&quot;" or so (actually double-processed html special characters), try to check "Allow HTML" option.

Source

You can edit the plugin if you need to change the look and feel of the output. There is only one file to deal with.
{CVS()}lib/wiki-plugins/wikiplugin_code.php{CVS}

History

Information Version
Danny Staple 12
View
Danny Staple 11
View
Mose 10
View
cerion And... what about starting at a different line number? i.e. for publishing code snippets (exp. for tutorials) 9
View
Mose 8
View
cinsk.shin 7
View
cinsk.shin 6
View
cinsk.shin 5
View
cinsk.shin 4
View
DennisDaniels code is bugged ... use at your own risk 3
View
Marc Laporte 2
View