Forums

This topic is locked

Dynamic Templates

Posted 09 Mar 2007 21:56:15
1
has voted
09 Mar 2007 21:56:15 Russell Jones posted:
I know it's possible to create master templates that let user's create and edit pages in the WYSIWYG design mode and only edit the editable content, but I'm wondering if you can embed a programming language such as PHP into these templates so you don't have to update your entire site when you change something in say the footer, and then republish everything. As far as I know in Design Mode, there's nothing available to have it process your PHP/ASP code so the page the person is editing in design mode looks like it would if it were a normal template.

Replies

Replied 13 Mar 2007 22:50:50
13 Mar 2007 22:50:50 billy imam replied:
unfortunately no, there is no option like that. Since the template is dynamic, DW assumes that the design will change based on some input (because of the php), so it can't render.

HOWEVER!! assuming you're using php only for importing the footer, if you have your header in a separate html file and only have the php import function withing the <? ?> tags, i think that should work.
Replied 14 Mar 2007 19:09:40
14 Mar 2007 19:09:40 Russell Jones replied:
Actually, the PHP includes being displayed in Design Mode is exactly what I need. I wasn't aware it was possible, thank you very much.

Reply to this topic