The main features of pfcTemplate
1. High efficiency
Because the program does not use regular expressions to analyze variables and blocks, but uses PHP's built-in string
processing function, so the efficiency may be slightly higher Compared with similar products
2. Ease of use
To use this class, you only need to simply create a class instance-> add files-> set variables/blocks-> [parse if there is a block]
-> It can be completed by parsing the file. Use common naming methods and provide easy-to-understand API interface methods.
3. Multi-level block processing
A lot can be achieved through the multi-level block processing function of the program Complex effects can be nested at unlimited levels (machine performance allows)
4. Templates that can be processed from multiple sources
Templates do not have to be made into files, they can be from databases or other sources.
$str = read_template_string();
$tpl->set_string('handle1', $str);
5. Variable customizability
The identifiers in the template can be adjusted by yourself.
For example: customize the identifier of a simple variable to "{/var