Regarding Including HTML page

Hi,

I have a  homepage.html which has a header and navigation menu.   In navigation menu i have menu items which has hyperlinks  to other html pages (page1.html, page2.html, page3.html) .In page1.html and page2.html i want to include the contents of homepage.html because it has header's description and menu description .  How do i include the contents of homepage.html in page1.html, page2.html and page3.html?

pigeon5566Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Steve BinkCommented:
If you're working in HTML, you'll need to copy the contents to each page that needs it.

If you can work in a server-side language, such as PHP, you can use the include() and require() functions.  
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
pigeon5566Author Commented:
Thanks for the info..    So your saying in HTML there is no tag to include the contents of other HTML Page.  So i need to use jsp for doing this?  
0
Steve BinkCommented:
Correct.  JSP, ASP, PHP...they can all do what you're looking for.
0
The Ultimate Tool Kit for Technolgy Solution Provi

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy for valuable how-to assets including sample agreements, checklists, flowcharts, and more!

Michel PlungjanIT ExpertCommented:
PS: There IS a tag to include content.
It is called iframe
0
Steve BinkCommented:
I did not consider an iframe for this question because of the nature of the include.  I suppose it would work (no reason it shouldn't), but I would not use an iframe for the header/menu of a page...I'd use an include file.
0
Michel PlungjanIT ExpertCommented:
If we take the comment


"So your saying in HTML there is no tag to include the contents of other HTML Page."

The answer could be iframe :)
0
Steve BinkCommented:
You are correct...I misspoke because a) I was focused on the context of the request, and b) I don't generally consider iframe to be a solution.  (my own personal bias against frames and their kin)

The <iframe> tag would be able to do the requested work.  Future readers can see more information about that concept here:

http://www.w3schools.com/tags/tag_iframe.asp

I recommend against using them as a general rule, and would still stand by my response here given the context of the request.
0
Michel PlungjanIT ExpertCommented:
Sure - I completely agree. If you have access to server side processing, iframes should be avoided.
That said, I am considering using them myself on my own site to be able to control bulk download - e.g. if you are not human, you do not get the iframe with the content
0
pigeon5566Author Commented:
Apologies for the delay
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
HTML

From novice to tech pro — start learning today.