PhpRiot
Download This Article
Download this article in PDF format with all listings and files.

Price: $5.00 AUD
(Approx. $4.45 USD)

More information
Related Books
Smarty PHP Template Programming And Applications

Smarty PHP Template Programming And Applications

Smarty is a templating engine for PHP. Designers who are used to working with HTML files can work...
Browse Articles
Ajax (4), APC (1), CAPTCHA (1), CSS (3), Debugging (1), File Upload (1), Google (3), Google Maps (2), JavaScript (11), JSON (2), MVC (1), MySQL (6), onbeforeunload (1), OOP (1), PHP (27), PhpDoc (1), PostgreSQL (6), Prototype (10), Reflection (1), RFC 1867 (1), Robots (1), Scriptaculous (1), SEO (1), Sessions (1), SimpleXML (1), Smarty (5), SOAP (1), SPL (1), Templates (2), W3C (1), XHTML (1), Zend Framework (1), Zend_Search_Lucene (1)

PhpRiot Newsletter
Your Email Address:

Creating Custom Block Tags in Smarty

Conclusion

In this article we have learned how to simplify your Smarty template code and to avoid repeating complex templates by using block plug-ins. Doing so allows us to easily to maintain and update templates as required without worrying about the implementation details of web page components.

To demonstrate the block functionality we implemented a plug-in called teaser, which could be used to output the summary of an article or document.

You can find the full block plug-in documentation on the Smarty web site at http://www.smarty.net/manual/en/plugins.block.functions.php.

In This Article


Tagged in ,