|
Posted by Beauregard T. Shagnasty on 09/27/08 11:16
Els wrote:
> Dave Moore wrote:
>
>
>> "Beauregard T. Shagnasty" <a.nony.mous@example.invalid> wrote
>>>>> You can output the HTML with your PHP code, of course.
>>>>
>>> All my sites incorporate "outside" files, including the <HEAD>.
>>
>> I'm sure that this can't be right. If you write a file out in
>> HTML using PHP, then it will already have the normal HTML tags,
>> like <HTML>, <HEAD> and <BODY>, etc. How can I introduce a FULL
>> 3rd party HTML file into this page without first stripping this
>> information out first?. Clearly simply 'include()'ing it will
>> result in a page with 2 lots of these tags which is clearly not
>> compliant.
>
> file.php: <?php include "bla.txt" ?>
Just prior to the include, I use:
$txttitle = "Specific Title For This Page";
> bla.txt:
> <html>
> <head>
> <title..... etc etc.
...where <title> is: <title><?php echo $txttitle ?></title>
It goes on to include all standard <meta> elements, links to
stylesheets, favicon, and so forth.
--
-bts
-This space intentionally left blank.
Navigation:
[Reply to this message]
|