template engine, the soln for a programmer & designer pa

Not for 'how-to' coding questions but PHP theory instead, this forum is here for those of us who wish to learn about design aspects of programming with PHP.

Moderator: General Moderators

Post Reply
mechamecha
Forum Commoner
Posts: 32
Joined: Thu May 31, 2007 8:49 pm

template engine, the soln for a programmer & designer pa

Post by mechamecha »

Hello,
I am working together w/ a web designer in creating a content management site. I am doing all the programming in php and the designer will be responsible for the html, css and art.

The problem is my web designer does not know how to code in php. Therefore, I need a workflow that separates php code from html layout and allows us to work on the site separately. Is a template engine the solution?

I have some experience w/ the Smarty Engine. With Smarty, this separation appears to be possible, although the designer would still need to learn some basic Smarty syntax. However would using a template engine be overkill for my purposes? Is there a better solution than resorting to a template engine?

I'm curious as to how most web development teams tackle this problem. Or is it the case today that a web designer must be knowledgeable in an internet scripting language such as php, javascript, etc...

Thank you
User avatar
Maugrim_The_Reaper
DevNet Master
Posts: 2704
Joined: Tue Nov 02, 2004 5:43 am
Location: Ireland

Post by Maugrim_The_Reaper »

The way I often see it done is for a designer to mock the page in pure html+css. Afterwards a programmer (or a designer with sufficient Smarty knowledge) can turn it into a template. It's still important that the designer and programmer work together though. As templates are churned out they may need additional data, and you'll need to adjust the application to supply it.
User avatar
pickle
Briney Mod
Posts: 6445
Joined: Mon Jan 19, 2004 6:11 pm
Location: 53.01N x 112.48W
Contact:

Post by pickle »

Templates are never a bad idea. A template engine would apply very nicely to your situation.

If you're somewhat familiar with Smarty & the designer doesn't know any template engine at all, I'd suggest taking a look at TemplateLite. It's a revision of Smarty that is much quicker than Smarty.
Real programmers don't comment their code. If it was hard to write, it should be hard to understand.
mechamecha
Forum Commoner
Posts: 32
Joined: Thu May 31, 2007 8:49 pm

Post by mechamecha »

Guys, thanks for the input!

I'll check out TemplateLite and see if it's a better alternative to Smarty.
User avatar
RobertGonzalez
Site Administrator
Posts: 14293
Joined: Tue Sep 09, 2003 6:04 pm
Location: Fremont, CA, USA

Post by RobertGonzalez »

To make it easy on you --> http://templatelite.sourceforge.net

It is an excellent tool that is fairly intuitive. I recommend it highly.
Post Reply