Blocks

A block, in ZML, is one or more continuous paragraphs, grouped semantically with an opening and closing block tag. Block tags are the only ones that share the syntax of BBCode:

[tag arguments]...[/tag]

The arguments in the opening tag are optional and depend on the tag in use. Zoglair comes with the following block tags:

Code

This tag is suitable for displaying preformatted text, such as source code snippets and program output. It uses a fixed-width (monospaced) font and preserves spaces and line breaks.

Example:

[code]
<?php
private static
function render_bloc_code($text, $args)
{
    $text = highlight_string(stripslashes(trim($text)),TRUE);
    $text = str_replace("n",'',$text);
    $text = zoglair::encode_text($text);
    return "<pre>$text</pre>";
}
?>
[/code]

Spoiler

This tag is suitable for keeping content hidden, unless the visitor clicks on a button to reveal it. It accepts the button's text as an optional argument. If none is given, a default “Spoiler!” text is used.

[spoiler Example]
At the end, the protagonist dies!
[/spoiler]

Quote

This tag is most useful on a discussion board (forum), as it is traditionally used for quoting past posts. It takes a lot of arguments, all of which are automatically supplied by zoglair, when used in a topic's post list.

(C) Nick B. Cassos - All Rights Reserved
powered by zoglair
page generated in 43ms (11 queries, 6ms)
invisible cron image