Sr. Web Developer
mediabistro.com
US-NY-New York

Justtechjobs.com Post A Job | Post A Resume

Comments for: babao20020907

Message # 1016688:
Date: 06/08/03 16:19
By: Hobbit
Subject: RE: Templates are DEAD! Long live PHP!

Templates are silly in uses such as this. You waste performance time and go through having to invent/learn another language for no reason.

The designer argument is ridiculous.

Designers are not stupid. If you give them a few snippets of what is commonly used and tell them where to use it, they'll pick up on it.

Get your processing done in the top of the file (or a header better) and provide the variables/arrays for the HTML page. If your designer can't remember how to set up a foreach loop, and/or do a php echo of a variable or array variable...give him/her a reference. It's not that complicated.

Here is what your designer needs to do 100% of what these templating systems buy you:

1) RENDERING A VARIABLE
<?= $title ?>



2) RENDERING AN ARRAY
<?
foreach ($userNamesArray as $username)
{
?>
<td><?=$username?></td>
<?
}
?>


1) RENDERING A 2D ARRAY (AS FROM A DB)
<?
foreach ($usersArray as $user)
{
?>
<td><?=$thing["username"]?></td>
<?
}
?>


That's it! And you know what? Other than the variable names (which you have to give them, template system or no...) THESE NEVER CHANGE. You can even give them a reference sheet! This can be learned in one sitting! They don't even need to know why/how it works...just that that's how it is done. And after doing it for about a week...they'll know it off the top of their head. Designers are not mongoloids, and php is not that difficult to understand.

Any webdesigner that is resistant to learning a LITTLE bit about a technology that would give them a broader skillset should be replaced with someone with a little ambition. If they can't learn that little list I gave you...it's going to be hell getting them to learn a templating system that isn't all that familiar to you yourself.

Previous Message | Next Message


Comments:
Constuctive Critisismscottybwoy08/30/07 05:50
PHP Programming,- text-based gameScott D05/02/07 17:28
Improvement to access to SubsectionsShai Lipkovich06/11/05 14:57
Contact php File to replace Mail@Peter Brennan02/16/05 03:19
Template helpAisha D02/04/05 12:19
All smarty isDumbass10/02/04 22:01
Templates live where you dare not treadBenjamin Smith04/24/04 03:10
agreed:RE: Templates are DEAD! Long live PHP!Roy Robin12/19/03 13:52
RE: Templates are DEAD! Long live PHP!Hobbit06/08/03 16:19
TemplateTamerDavorin Rusevljan01/05/03 10:17
RE: Templates are DEAD! Long live PHP!L long12/17/02 16:32
Introducing {PHPTMPL}Geraud Krawezik11/18/02 07:59
RE: Templates are DEAD! Long live PHP!Sonic_Molson11/15/02 22:04
RE: Templates are DEAD! Long live PHP!Patrick Fitzgerald11/03/02 12:57
Wow... Needs lots of improvementeruanno10/22/02 09:52
RE: Templates are DEAD! Long live PHP!Michael Sinclair10/14/02 15:07
RE: Templates are DEAD! Long live PHP!Harry Fuecks10/09/02 06:05
This is what I would doJoe10/07/02 02:33
RE: Templates are DEAD! Long live PHP!Michael Sinclair10/06/02 08:31
RE: Templates are DEAD! Long live PHP!haj10/02/02 02:44
RE: Whats wrong with FastTemplate or phplibhaj10/02/02 02:36
RE: Templates are DEAD! Long live PHP!M. Thornton09/30/02 14:55
RE: Templates are DEAD! Long live PHP!Harry Fuecks09/29/02 08:13
RE: Templates are DEAD! Long live PHP!bigSys09/28/02 11:48
RE: Templates are DEAD! Long live PHP!c-dawg09/27/02 19:35
PHP replication of Zope and JSP for templatigMichael Glazer09/27/02 17:49
RE: Don't be too criticalBDKR09/27/02 11:06
RE: Templates are DEAD! Long live PHP!Adalberto09/27/02 10:54
RE: NEED HELP URGENTLY, PLEASEadd php project09/25/02 05:49
NEED HELP URGENTLY, PLEASEEddieson09/24/02 12:00
RE: Templates are DEAD! Long live PHP!dotwebbie09/23/02 11:40
The best template engine is SmartyOskars09/21/02 16:32
patTemplateMitchell Landry09/21/02 02:14
RE: Templates are DEAD! Long live PHP!Harry Fuecks09/20/02 06:45
RE: Whats wrong with FastTemplate or phplibZpiff09/20/02 04:32
RE: Templates are DEAD! Long live PHP!Yuriy Horobey09/19/02 02:31
Templates are DEAD! Long live PHP!Harry Fuecks09/18/02 12:21
RE: Whats wrong with FastTemplate or phplibanimosity09/18/02 12:19
Don't be too criticalJason09/18/02 09:21
RE: why notTom Anderson09/16/02 12:06
Uhm... ya.. ok...Vincent09/15/02 08:38
one more thingAivar Annamaa09/15/02 04:34
ComplexTemplateAivar Annamaa09/15/02 03:55
RE: why notClaudio Bustos09/14/02 16:26
RE: why notkybosh09/13/02 19:54
why notPhynias09/13/02 11:22
Whats wrong with FastTemplate or phplibZpiff09/11/02 08:24
why not simply use patTemplate or alike?NightOwl09/11/02 02:41
just use vlibTemplateKelvin Jones09/10/02 04:31
Ignore this article: save brain cells.Tom Anderson09/09/02 15:23
 

If you are looking for help, please post on the appropriate forum here. Your questions will be answered much more quickly.

Add A Comment:

Name:

Email:

Subject:

Message:

To reduce spam posts, messages are now manually approved

You are not [logged in]. That means your account will not get credit for this post.