Is it possible to include a header and footer file using HTML? I have my file as a .html and need to be able to include the HTML for the header and footer. Anyone know how I can do this?
Is it possible to include a header and footer file using HTML? I have my file as a .html and need to be able to include the HTML for the header and footer. Anyone know how I can do this?
there are many ways to do this, how would you like to do it ifram or include script.
I have both i can post them but don't have access to them
The web in one word.
Either you use an <iframe> tag, or you do something much better: PHP
The PHP code there is:
<?php
include("yoursite.php");
?>
But if your host won't let you use PHP, you should use <iframe>:
<iframe width="number" height="number" border="0"></iframe>
no no no, there is no need for php i use the following code.
works all browsers.
<!--webbot bot="Include" U-Include="header/head.html"
TAG="BODY" -->
and you save page as .html
The web in one word.
PHP works in all browsers too.
But not on all servers. That relies on the server being set to interpret the file like that. If you have PHP, it would work the same way. PHP works in all browsers too... that's because both ways output just html, and the browsers doesn't need to do anything but parse the html... unlike javascript or an iframe tag where the browser actually does it.
I don't know if the OP was even talking about this, though. Do you mean like in word, with a header and footer with titles and such? Not sure how that applies... do you mean when printing? Or?
Daniel - Freelance Web Design | <?php?> | <html>| español | Deutsch | italiano | português | català | un peu de français | some knowledge of several other languages: I can sometimes help translate here on DD | Linguistics Forum
- John________________________
Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate
Bookmarks