|
Posted by Adrienne Boswell on 04/22/07 16:54
Gazing into my crystal ball I observed =?ISO-8859-15?Q?Manfred_Preu=DFig?
= <PreussigM@web.de> writing in news:f0ffta$if1$1@news.albasani.net:
>> However, I will say that one should not try to include an entire HTML
>> page within another, because one would get duplicate head elements.
> Of course. If I do it like this I will make it through a special page
> only for this. But even there it was the question if tags like <HTML>
> have to be in there too. The duplicate header I think I need at one
> point: To incorporate the CSS. Or is the setting in the including file
> valid for the included file too?
>
Here's a typical example of pages for me:
<? thispage = "page title"; //name of the page
thisurl = "page.url"; //the actual url ?>
<? include file = "linkrel.php" ?>
</head>
<body>
<? include file = "nav_inc.php" ?>
<? include file = "h1_inc.php" ?>
<div id="content">
</div>
</body>
</html>
-- linkrel.php --
Doctype declaration
connection string
head elements
external stylesheet
external javascript
master functions if I'm working in asp
Notice that there is a closing head element below the linkrel include.
This is to have the ability to use document level style, in case that one
page needs to have a special style that is not in the external file, or
needs to override the external sheet.
-- nav_inc.php --
Navigation, usually includes a routine that sees if thisurl is the same
as the script name, and if it is, it uses a class of currentpage.
-- h1_inc.php --
This may be a header, but the h1 element and the title element in
linkrel.php use the thispage statement at the very top of the document.
--
Adrienne Boswell at Home
Arbpen Web Site Design Services
http://www.cavalcade-of-coding.info
Please respond to the group so others can share
[Back to original message]
|