Fat-Free Framework  3.4.0  Overview Class List Hierarchy
Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes | List of all members
Template Class Reference

XML-style template engine. More...

+ Inheritance diagram for Template:

Public Member Functions

 extend ($tag, $func)
 
 __call ($func, array $args)
 
 parse ($text)
 
 __construct ()
 
- Public Member Functions inherited from Preview
 token ($str)
 
 resolve ($str, array $hive=NULL)
 
 render ($file, $mime='text/html', array $hive=NULL, $ttl=0)
 
- Public Member Functions inherited from View
 esc ($arg)
 
 raw ($arg)
 
 alias ($key, $arg=null)
 
 render ($file, $mime='text/html', array $hive=NULL, $ttl=0)
 
 afterrender ($func)
 

Public Attributes

 $custom =array()
 Custom tag handlers.
 
const E_Method ='Call to undefined method %s()'
 
- Public Attributes inherited from View
 $trigger
 post-rendering handler
 
 $level =0
 Nesting level.
 

Protected Member Functions

 _set (array $node)
 
 _include (array $node)
 
 _exclude ()
 
 _ignore (array $node)
 
 _loop (array $node)
 
 _repeat (array $node)
 
 _check (array $node)
 
 _true (array $node)
 
 _false (array $node)
 
 _switch (array $node)
 
 _case (array $node)
 
 _default (array $node)
 
 build ($node)
 
- Protected Member Functions inherited from Preview
 build ($node)
 
- Protected Member Functions inherited from View
 sandbox (array $hive=NULL)
 

Protected Attributes

 $tags
 Template tags.
 
- Protected Attributes inherited from Preview
 $mime
 MIME type.
 
- Protected Attributes inherited from View
 $view
 Template file.
 

Additional Inherited Members

- Static Public Member Functions inherited from Prefab
static instance ()
 

Detailed Description

XML-style template engine.

Constructor & Destructor Documentation

Template::__construct ( )

Class constructor return object

Member Function Documentation

Template::__call (   $func,
array  $args 
)

Call custom tag handler

Returns
string|FALSE
Parameters
$funccallback
$argsarray
Template::_case ( array  $node)
protected

Template -case- tag handler

Returns
string
Parameters
$nodearray
Template::_check ( array  $node)
protected

Template -check- tag handler

Returns
string
Parameters
$nodearray
Template::_default ( array  $node)
protected

Template -default- tag handler

Returns
string
Parameters
$nodearray
Template::_exclude ( )
protected

Template -exclude- tag handler

Returns
string
Template::_false ( array  $node)
protected

Template -false- tag handler

Returns
string
Parameters
$nodearray
Template::_ignore ( array  $node)
protected

Template -ignore- tag handler

Returns
string
Parameters
$nodearray
Template::_include ( array  $node)
protected

Template -include- tag handler

Returns
string
Parameters
$nodearray
Template::_loop ( array  $node)
protected

Template -loop- tag handler

Returns
string
Parameters
$nodearray
Template::_repeat ( array  $node)
protected

Template -repeat- tag handler

Returns
string
Parameters
$nodearray
Template::_set ( array  $node)
protected

Template -set- tag handler

Returns
string
Parameters
$nodearray
Template::_switch ( array  $node)
protected

Template -switch- tag handler

Returns
string
Parameters
$nodearray
Template::_true ( array  $node)
protected

Template -true- tag handler

Returns
string
Parameters
$nodearray
Template::build (   $node)
protected

Assemble markup

Returns
string
Parameters
$nodearray|string
Template::extend (   $tag,
  $func 
)

Extend template with custom tag

Returns
NULL
Parameters
$tagstring
$funccallback
Template::parse (   $text)

Parse string for template directives and tokens

Returns
string|array
Parameters
$textstring

The documentation for this class was generated from the following file: