From 2a40eb87c8c679a25ddb42587a1934e02312cb4a Mon Sep 17 00:00:00 2001 From: Kevin Chabowski Date: Thu, 4 Oct 2012 16:04:55 +0200 Subject: improved and fixed docu. * can now also convert line breaks to
, if parameter lines is true. * now uses PHP's htmlspecialchars instead of htmlentities since it only escapes the minimal neccessary chars which should work, if encoding is handled correctly. * Fixed 2 markup bugs in docu/language_definition.html --- docu/language_definition.html | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'docu/language_definition.html') diff --git a/docu/language_definition.html b/docu/language_definition.html index e311907..2c809bc 100644 --- a/docu/language_definition.html +++ b/docu/language_definition.html @@ -113,7 +113,7 @@ Just like their XML counterparts, they can wrap other elements (<ste:foo>bar<ste:baz>herpdederp</ste:baz></ste:foo>) or can be self-closing (<ste:foo />). And they can have additional parameters (or "attributes", using the XML terminology): <ste:foo bar="baz" />

-

A Tag is wrapped in < and >. The tag's name always start with ste: and can then consist of letters, numbers and underscores (Regex: [a-zA-Z0-9_]+).

+

A Tag is wrapped in < and >. The tag's name always start with ste: and can then consist of letters, numbers and underscores (Regex: [a-zA-Z0-9_]+).

If the tag is self-closing, the last char is a / (e.g.: <ste:foo />).

If the tag is a closing one, the first char is a /. An opening Tag does not have a /.An example of an opening-closing Tag pair wrapping the text bar: <ste:foo>bar</ste:foo>

@@ -474,13 +474,16 @@

Standard Library

The Standard Library contains some useful tags, which are not builtin but still always available.

ste:escape

-

Escapes characters that are reserved for HTML (e.g. <, >, ", &). The text to escape is the tag's content. +

Escapes characters that are reserved for HTML (e.g. <, >, ", &). The text to escape is the tag's content.

Example:

<ste:escape>Foo & bar...</ste:escape>
Result:
Foo &amp; bar...

+

+ If the optional parameter lines is true (i.e. not empty), then additionally line breaks are converted to <br />. +

ste:strlen

Returns the length of then content.

-- cgit v1.2.3-70-g09d2