Several common PHP template Engines

Source: Internet
Author: User
Tags php compiler php template xml parser smarty template

PHP template engineIt is widely used in separation templates and layout.

Using the PHP template engine can make website maintenance and updates easy, create a better development environment, and make development and design work easier to combine.

It certainly has some limitations, such as performance (most PHP template engines do better in this aspect) and the need to learn new syntaxes (occasionally ).

Here, we useTemplate engineIt is not necessarily suitable for every project. If a website has only a few pages, it is likely not needed. If you are developing portals, e-commerce websites, or other Web applications, you can use them to improve the development process.

Here is19 PHP template engines,They all have friendly features and are under continuous development.

Click the image or title name to download

Smarty

Smarty is an official PHP template. The previous official website address is http://smarty.php.net/. because it is too popular, the new domain name http://www.smarty.net/will be used later /.

Smarty is a php template engine. More accurately, it separates logical programs from external content and provides an easy-to-manage method. It can be described as an application programmer playing a different role with the artist, because in most cases, they cannot be the same person.

One of the features of Smarty is "template compilation ". It means that Smarty reads the template file and uses it to create a php script. These scripts will be executed after they are created. As a result, no Syntax Parsing is spent on the template file, and each template can enjoy something like a Zend accelerator (http://www.zend.com) or a PHP accelerator (http://www.php-accelerator.co.uk ). This php compiler high-speed cache solution.

Dwoo

Dwoo is a PHP5 template engine. Compatible with the Smarty template, which is fully rewritten based on the Smarty syntax. Supports extension of its functions through plug-ins.

Savant

Savant is a powerful but lightweight object-oriented PHP template engine. Unlike its template system, Savant does not compile the Template into PHP by default, but uses PHP as its template language. Therefore, you do not need to learn a new tag system. Savant has an object-oriented template plug-in system and output filter that allows you to quickly add new behaviors to it.

Template Blocks

Template BlocksIsVisualized template engine lThe template engine is lightweight, flexible, and highly scalable.

You can generate any extensions of static content and use popular extension suffixes, such as. html,. htm, And. php. They will all load the same content.

Open Power Template

The new Open Power Template contains a built-in xml parser that fully understands your html code structure. It can find unclosed labels in the structure and perform complex actions. Each template is compiled into php code so that the execution speed is fast. You can use the php accelerator for acceleration and the results will be cached.

TinyButStrong

TinyButStrong (TBS) is a PHP template engine that separates PHP scripts from HTML files. TBS is designed to use any visual HTML editor to compile tbs html template pages.

Rain TPL

Easy to use and install the engine. There are 6 labels, 3 php functions, and 2 php classes. What you see in Rain TPL is very friendly. You can use the s relative paths of img/cs to convert them to the correct server paths.

PHPTAL

PHPTALIsZPTPHP Execution. In short,PHPTALIs a php xml/XHTML template library.

PHP Template Engine

ThisTemplate enginePHP is not a template script language.

It has a simple user authentication, session and cookie system.

Template Lite

Template Lite is a very fast and small HTML Template engine. This engine supports most of the functions and filters of the Smarty template engine.

VTE-Vivvo Template Engine

VTEInitially created for Vivvo CMS, but released for free, it is a lightweight, easy to use, powerful and scalable template engine. It can do recursion, object requirements, array, but still kept in a single volume, less than 1000 lines of code! The VTE language is based on xml, including tags and attributes.

XTemplate

XTemplate is a template engine for PHP. It allows separate storage of HTML code and PHP code. XTemplate contains many useful functions such as nested program blocks and various types of interpolation variables. Its code is very concise and optimized.

VlibTemplate

A fast and all-powerful template system that contains a cache and debugging class.

PHP-Sugar

Its smarty has the same spirit. A flexible assembly engine that expresses usage similar to php itself. It also has a clean and easy-to-understand syntax, and the output is html Escape.

FXL Template

FXL TemplateIs an easy-to-use template engine that contains all the functions of an engine system.

Blitz templates

Blitz templatesIs a quick template engine.

Vemplator

Only 220 lines of code,VemplatorProvided:

  • Condition Statement: if/else and switch Declaration
  • Customer. name)
  • Join and number array (row [0] and rows [1] ['name'])
  • For-each looping over arrays (Association and digital index)
  • Supported des (the supported ded template is resolvable and separated from the cache)
Template Engines Under PEAR

4 PEAR packages on templating:

  • HTML_Template_Flexy
  • HTML_Template_IT
  • HTML_Template_PHPLIB
  • HTML_Template_Sigma
QuickSkin

You really likeWhich PHP template engine is used?& Why?

19 Promising PHP Template Engines | WRD

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.