Re: [PHP3] Re: [PHP Template] Re: [PHP3] Re: [PHP Template] Template Discussion

From: Date: Wed, 22 Mar 2000 21:22:48 +0000
Subject: Re: [PHP3] Re: [PHP Template] Re: [PHP3] Re: [PHP Template] Template Discussion
References: 1  Groups: php.template 
Request: Send a blank email to php-template+get-430@lists.php.net to get a copy of this message
This one is obvious to me just by looking at it. Plus, there's not much chance of me doing something to screw it up. {section} {@Name}<br> {@Address}<br> {@Phone}<p> {/section} Now this one, is an open invitation for trouble. Once you start adding ;, +, $,=, <,( and a space here but not there, the designer is afraid they will break it just by looking at it, let alone trying to add html around and inside of it. function loop($arrayvar) { for($loop = 0; $loop <= count($arrayvar); $loop++) { echo $arrayvar[$loop]; echo $arrayvar[$loop]; echo $arrayvar[$loop]; } } John Coggeshall wrote: > > >{section} > > {@Name}<br> > > {@Address}<br> > > {@Phone}<p> > >{/section} > > or > > ><? for($loop=0; $loop<=count($Name); $loop++): ?> > > <? print $Name[$loop]; ?><br> > > <? print $Name[$loop]; ?><br> > > <? print $Name[$loop]; ?><p> > ><? endfor; ?> > > How about this... > > backend.php3 > -=-=-=-=-=-=-=- > function loop($arrayvar) { > > for($loop = 0; $loop <= count($arrayvar); $loop++) { > > echo $arrayvar[$loop]; > echo $arrayvar[$loop]; > echo $arrayvar[$loop]; > > } > > } > -=-=-=-=-=-=-=- > EOF backend.php3 > > Then your "template".... > > <? loop($Name); ?> > > Now I'm definately not a designer... but boy that looks simple to me. > > John -- Anne Holz | anne@ispi.net art director | ispi | voice: +1.402.441.3295 http://www.ispi.net | fax: +1.402.483.5418

« previous php.template (#430) next »