PDA

View Full Version : DW Templates vs. PHP includes



dru_nasty
January 29th, 2009, 10:14 AM
I'd like to get peoples feedback on pros/cons using PHP Includes vs. Dreamweaver templates when developing "template" based sites.

I'm trying to develop a standard practice in-house at our company. Prior to me being here everything has been done using DW templates. I however prefer php and not even relying on any built in DW features.

So here's a few off the top of my head:

PHP Pros
• don't need to upload the entire site when updating a template item
• transfers easily to other developers (don't need DW to edit things)

DW Pros
• easily edit each pages' meta data and titles (although php can do this with a little coding)
• designers don't need knowledge of PHP (IMO they should)
• integrates well with Adobe Contribute if a client needs it
• don't need php installed on server (but really, what server nowadays doesn't have it)

As far as pros/cons when working on same project with multiple designers I can't say since we haven't had much experience. But I can say, when i had to update a DW template that was on someone elses local that was quite a pain.

Hopefully this invokes some good feedback.

DDD
January 29th, 2009, 11:45 AM
Well if everyone in the system does not use DW, then the usefulness of DW goes out the window. The power of DW template comes into play when you nest them. And you can setup a very apparent hierarchy with them. Also you need to consider the skill level of your team. If it is a bunch of receptionists and stuff making updates then you may want to go with DW templates because it plays well with things like Contribute. But if everyone doing updates is strong in coding and practices, then you can actually use both quite well together. But the key will be documentation and Info Architecture.

actionAction
January 29th, 2009, 11:50 AM
You don't need PHP knowledge to update the site, you just make a static header, footer, etc. in html, and your php page compiles them into one file. This allows changes to be made to 1 header file, 1 footer file, and the content can change as needed. I don't think that there really is much to argue there (I am with you).

I honestly think you should use a combo, though (best of both worlds), with something like this prepopulated:


<?php

$page_title = "";
$meta_data =<<<META
ENTER YOUR META DATA HERE
META;
?>

When they create their html page, they switch to source view and enter the page title and meta data (without having to know php), and you can use a switch statement to ensure that they have filled it in, if they haven't, enter default values.