By: Chris Fordham
Date: 2006-04-11
Time: 09:28
|
Dynamic HTML templates
Lets say I have a group of templates for my site.
Each template has the same header and footer.
But I want to change the common header and footer without changing every single template.
I can't embed PHP script into the templates ie. include('common_header.php')
I need a way so each page can have a common header that is parsed and a way of doctype switching eg. some pages will use xhtml 1.0 and some will use 1.0.
Any suggestions on the correct way to do this?
|
By: Skrol29
Date: 2006-04-11
Time: 12:04
|
Re: Dynamic HTML templates
Hello,
Parameter "file" enables you to insert the content of a file inside the template. You can use this parameter on a [onload] tag which is processed automatically.
Here is what is usually done:
<html>
...
<body>
[onload;file=header.htm]
...
[onload;file=footer.htm]
</body>
</html>
|
|
By: Chris Fordham
Date: 2006-04-11
Time: 12:54
|
Re: Dynamic HTML templates
Sweet thanks Skrol29.
I just realised that there are sub-templates which appears to be a good/proper way of doing it too.
|
|
Posting in progress.
Please wait...
|