Results 1 to 2 of 2
10-11-2010, 08:40 AM #1
Include an HTML File into an another html file.
I've created a seperate html files for navigation, content and footer. I want to club those files. All the navigation, content, footer files resides in the same directory where the index.html file resides. I want to include the above mentioned html files inside the index.html. I have tried using the following in index.html file
<!--#include virtual="topbanner.html" -->
I also tried using the asp code which also fails. I tried with asp by changing all the html file extensions as .asp. Then i tried to place the following asp code in index.asp file as
<!--#include file="topbanner.asp" -->
Kindly solve my problem. This is an urgent thing to do for me.
11-03-2010, 01:01 PM #2
Re: Include an HTML File into an another html file.
Some web servers will only allow those server-side includes when the document has an extension .shtml
My advice would be to rename your index.html to index.shtml, upload it and try browsing to it to see if the includes works.
If it doesn't then, you need to contact your web server administration to allow the .shtml extension to be parsed.