- From: Noel R Schutt <nrschutt@juno.com>
- Date: Thu, 16 Apr 1998 18:20:49 EDT
- To: www-html@w3.org
>On Thu, 16 Apr 1998, Pascal Sitbon wrote:
>
> I don't understand why there's no instruction to include a file in html
in another. For > example, I have a menu.html file which describes the
main menu, and for all *.html > in the site, I would include the menu
simply by putting something like :
> <INCLUDE HREF="menu.html">
> (like the \insert{} command in LaTeX or the #include in C langage)
> I think that this can be useful in many cases.
<INCLUDE HREF="[file name]"> sounds like a very good method of doing
this.
On Thu, 16 Apr 1998 04:33:54 -0400 (EDT) Gregory Martin Pfeil
>There is a way, but it requires that the server has SSI (Server Side
Includes) >available. A lot of commercial Web hosts turn off the
functionality in order to improve >security.
>
>For example, to include menu.html, you could use:
> <!--#include file="menu.html"-->
#include is great, IF you can use it. I can't on either of the hosts I am
on (www.geocities.com and www.online.tayloru.edu)
There should be a client side version to replace #include when it is not
available. If the user has a cash turned on, a client side include could
save bandwidth. A client side include would also be useful for files that
are being accessed from a disk instead of a server. Maybe client side
includes should be left for XML though...
An example of how I would use <INCLUDE>:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML [version]>
<HTML>
<HEAD>
....
<LINK REL="STYLESHEET" HREF="[CSS file]" TYPE="TEXT/CSS">
</HEAD>
<BODY>
<INCLUDE HREF="header.html">
...body...
<INCLUDE HREF="navbar.html">
<INCLUDE HREF="footer.html">
</BODY>
</HTML>
header.html
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML [version]>
<HTML>
...header code...
</HTML>
navbar.html
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML [version]>
<HTML>
[ <A HREF="home.html">Home</A> ]
[...more options...]
</HTML>
footer.html
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML [version]>
<HTML>
<P>
<ADDRESS>
Last updated [date] by Noel Schutt.
<BR>
© copyright 1998, Noel Schutt. Please read my <A
HREF="copyright.html">copyright page</A>.
<BR>
Contact me at: <A HREF="NRSchutt@juno.com">NRSchutt@juno.com</A>
</ADDRESS>
</P>
</HTML>
-Noel Schutt
NRSchutt@juno.com
96983@tayloru.edu
http://www.geocities.com/CapeCanaveral/Lab/5450
_____________________________________________________________________
You don't need to buy Internet access to use free Internet e-mail.
Get completely free e-mail from Juno at http://www.juno.com
Or call Juno at (800) 654-JUNO [654-5866]
Received on Thursday, 16 April 1998 18:31:48 UTC