O'Reilly logo

PHP 5 Unleashed by John Coggeshall

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 7. Using Templates

As PHP becomes more of a central component of a website, the need to properly manage your code base becomes more important. This is especially true as multiple people start working on the same website. One of the best ways to keep your PHP applications manageable is to separate the HTML of your website from the actual PHP code that powers it. This process is called separation of presentation logic from application logic. In this chapter, I examine some of the most common methods in use for separating presentation and application logic, including the PHP template package called Smarty.

The What and Why of Templates

In PHP, the most common method of separating ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required