literal
Summary
Instructs the parser to ignore a block of template code.
Usage
{literal}
...
{/literal}Description
This function can be used to encapsulate foreign code (for example JavaScript) that makes use of characters that may confuse the template parser. Everything that is inside a literal block will be completely ignored by the parser.
Examples
Example 1
{literal}
<script language="JavaScript" type="text/javascript">
<!--
function foo()
{
alert ( "Call me" );
}
//-->
</script>
{/literal}This example demonstrates how to include a JavaScript snippet in a template using the "{literal}" and "{/literal}" notation.
Contributors
- Balazs Halasy Updated
Comments
Add a comment