Re: mixing HTML and PHP code

From: Date: Fri, 12 Jan 2001 23:49:56 +0000
Subject: Re: mixing HTML and PHP code
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-34325@lists.php.net to get a copy of this message
> <table> > {:each:output} > <tr> > <td>{output}</td><td>{more_output}</td> > </tr> > {:next:more_output} > {:end} > </table> > > Even a pot-smoking mac-using hippie web designer can understand that. :-) > And it's readable in Dreamweaver or GoLive or any of those visual HTML > tools. For Dreamweaver I added a little custom definition that makes a nice > icon wherever it sees a template tag in the HTML file. Speaking as a not-pot-smoking mac-using only partially hippie web designer: why bother with creating your own syntax? why not just explain some _super_basic_ php syntax to the "html dude" and have him do the code himself? also, dreamweaver nicely ignores <? ?> etc. -a > ...and our PHP geeks just stuff a results array into the template. Too > easy. > > - Tim > http://www.phptemplates.org > >> <TABLE> >> <? >> while (fetch_row_from_query()){ >> $output = data_from_fetched_row(); >> $more_output = more_data_from_fetched_row();?> >> <TR> >> <TD><?echo $output?></TD> >> <TD><?echo $more_output?></TD> >> </TR> >> <?}?> >> </TABLE> > > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net >

« previous php.general (#34325) next »