[Phplib-users] Re: url() in templates
Brought to you by:
nhruby,
richardarcher
From: Richard A. <rh...@ju...> - 2001-08-14 11:32:43
|
At 12:40 PM +0200 14/8/01, Guenther Theilen wrote: >> You don't want to be executing your templates!! > >Why don't I? (Sorry, I just start working with the PHPLIB.) The concept of templates is to separate the HTML from the logic. If you start putting logic in the template (whether that's embedded PHP code or some sort of IF tag) you're creating something *very* complicated. Much better (IMHO) to program the logic into the PHP script and use the template to control the layout of the page. I have seen one or two cases where if clauses and loops appeared to be suitable in a template, but in each case I thought the overall result was more complicated to maintain and configure than it would have been with the logic all in the PHP application. My rant isn't particularly relevant in your situation, as the job you want done is perfectly suited to the existing template.inc :) ...R. |