News Feed
Sections




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

Andrew Podner:
Lithium Building Views Using Layouts
February 13, 2013 @ 11:54:04

Andrew Podner has written up a new post for his site today about building views/layouts in Lithium and make the maintenance of your application simpler in the long run.

The last time I wrote about the Lithium framework, the focus was on getting information out of a MySQL database. Once you have that information, in many cases you will want to show it to the user. In this installment, we are going to look at how Lithium implements layouts for your output in an effort to improve reusability of code, which ultimately improves the developer's ability to quickly get applications up and running and it makes maintenance down the road that much easier.

He talks about the basic structure of an application (on the file system) and where the layouts and views live inside it. He includes a sample layout that defines areas for things like title, scripts, character set and main content. Code is also included showing how to use it in your application. There's also a bit about setting up a default layout in your "_init" method if you'd like to use it across the entire application.

0 comments voice your opinion now!
lithium view layout tutorial framework


blog comments powered by Disqus

Similar Posts

NetTuts.com: Learn to Create Interactive Drill-Down Dashboards with PHP and FusionCharts

Nefarious Designs: Object-Oriented PHP Part 1: Definition

Richard Thomas: Solar Gets Firephp Support & a Base Controller Tip

WebSpeaks.in: Learn Simple Method Chaining in PHP

Christoph Dorn's Blog: Profiling queries with Zend_Db_Profiler_Firebug


Community Events





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


bugfix voicesoftheelephpant framework community interview language zendserver introduction release tips conference symfony laravel list threedevsandamaybe series podcast deployment code api

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