Including content of one file of HTML in another?

Subject: Including content of one file of HTML in another?
From: "Hart, Geoff" <Geoff-H -at- MTL -dot- FERIC -dot- CA>
To: "TECHWR-L" <techwr-l -at- lists -dot- raycomm -dot- com>
Date: Wed, 19 Dec 2001 15:03:51 -0500

Guy Haas is looking for help for his daughter, who asks: <<"Isn't there a
way to create a navigation bar and store it in one file, and then have the
pages of a website call it from that file and stick it at the top of their
content? That would make it a LOT easier to modify the navbar, as you
wouldn't have to tweak EVERY PAGE to do it..." She has HomeSite and
Dreamweaver at her disposal, but would rather not do wholesale
search-and-replace to make the same navbar change in each of N files in the
site.>>

I can't speak to HomeSite, but Dreamweaver will do this easily. The problem
you describe represents a tailor-made opportunity to learn to use page
templates (which are described quite well in the Dreamweaver documentation).
If you build a simple page template that closely resembles the pages that
you want to standardize, and include the navigation bar in that template,
you can then apply that template to each existing page. The pages will
generally reformat nicely to take on the new layout imposed by the template,
and subsequently, you can easily maintain the Web pages (e.g., update the
navigation bar to include new sections of the site) simply by updating the
template. The problem you'll typically encounter is when the pages vary
greatly in their contents and layout; in that case, you'll either have to
reformat these pages (a good idea anyway, because the results are more
consistent for users) or create a new template for each group of similar
pages.

--Geoff Hart, FERIC, Pointe-Claire, Quebec
geoff-h -at- mtl -dot- feric -dot- ca
"User's advocate" online monthly at
www.raycomm.com/techwhirl/usersadvocate.html

"Any sufficiently advanced technology is indistinguishable from a
personality, and an obnoxious one at that."-Kim Roper

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Collect Royalties, Not Rejection Letters! Tell us your rejection story when you
submit your manuscript to iUniverse Nov. 6 -Dec. 15 and get five free copies of
your book. What are you waiting for? http://www.iuniverse.com/media/techwr

Have you looked at the new content on TECHWR-L lately?
See http://www.raycomm.com/techwhirl/ and check it out.

---
You are currently subscribed to techwr-l as: archive -at- raycomm -dot- com
To unsubscribe send a blank email to leave-techwr-l-obscured -at- lists -dot- raycomm -dot- com
Send administrative questions to ejray -at- raycomm -dot- com -dot- Visit
http://www.raycomm.com/techwhirl/ for more resources and info.


Follow-Ups:

Previous by Author: Appropriate content for index?
Next by Author: Including content of one file of HTML in another? (take II)
Previous by Thread: RE: Including content of one file of HTML in another?
Next by Thread: Re: Including content of one file of HTML in another?


What this post helpful? Share it with friends and colleagues:


Sponsored Ads