Download for PHP  R515 (beta)
Welcome » Extensions » Formatters
Expand

Input document

.

Upload document:

Formatters

Full reference: Formatters
.(see) See also Extension list.

To invoke a formatter wrap the text to format in dual percent signs (%%) and supply the formatter’s name in parenthesis after the opening %%. If supported, you can pass additional parameters to it after its name; you can also chain it with other extensions with a semicolon.

Formatter names are case-insensitive. Inside the formatter normal markup doesn’t work.

PHP
echo 'Hey, people of the Earth!';

Now a bit more complex example:

Example.php (downloaded 1487 times)
class AClass {
  public $aField;
} // AClass

But it looks boring without any color, right? Let’s chain it with a PHP formatter:

Example.php (downloaded 1465 times)
PHP
class AClass {
  public 
$aField;
// AClass

Much better! You can use the inline form too: snippet.wiki «Hello, the world of stars.» © Anonymous.
Another example: code.php PHPecho 'PHP';

Let’s dive deeper (try moving your mouse inside):

"Wacko" is the name of
our markup that originates
from ((WP:WackoWiki)) that
gave us the basic idea.

«Wacko» is the name of
our markup that originates
from WackoWiki that
gave us the basic idea.

Here we have chained 3 formatters: Mirror that takes your input and formats it in some way, DomHint that, again, takes your input and highlights nodes there, and, finally, Wacko – that markup you’re reading documentation about.

Try removing any component from the above example (e.g. make it «DomHint; Wacko») and see how it affects the output.

Languages