News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

SitePoint PHP Blog:
DOM vs. Template
September 25, 2008 @ 11:18:25

In this new post to the SitePoint PHP Blog there's a look at using a small templating engine recently released by Fredrik Holmstrom that takes a different tack on working with template files - it parses them into a DOM structure.

The main difference to traditional template engines (Such as Smarty), is that the template it self doesn't have any imperatives within. In fact, the template doesn't even have to be written to the template engine, to be used - Any markup can be used as a source.

The templating system uses Domlings, bits of HTML to match against and replace with the bound information. A few examples are included - a simple binding, how to switch out a block of HTML, pushing it back in and looping over a block of information to do some search and replace.

0 comments voice your opinion now!
dom template smarty domlings html replace


blog comments powered by Disqus

Similar Posts

Zend Developer Zone: Integrating Smarty with the Zend Framework

JSClasses.org Blog: Lately in JavaScript podcast - Episode 5 (Javascript to Replace PHP?)

PHPit.net: Book Review: Smarty PHP Template Programming and Applications

Roy Ganor-Shwaartz's Blog: PDT Gets Smarty

Oracle Technology Network: Creating an Ajax Process Using PHP and Oracle


Community Events

Don't see your event here?
Let us know!


language series symfony podcast framework threedevsandamaybe introduction release extension voicesoftheelephpant interview api library laravel5 opinion security version laravel unittest community

All content copyright, 2015 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework