RE: Include pieces of code in an HTML file

Where have I heard this discussion before?

> Is there a way in XHTML 1.0 or HTML 4.0 to include a piece of code
in an HTML
> file from another file?

13.3 General Inclusion: the OBJECT element
http://www.w3.org/TR/html40/struct/objects.html#h-13.3

> and that I wish to keep one copy of that statement so that when
> I update it all pages are automatically updated. I do not want
> to use server-side tags, cgi or JavaScript to do that.
> How can I do that?  What's about
> <INCLUDE SRC="legal/rightsnotices.html" RESOLVENT="yes" />

Why not some form of server auto-inclusion?  Why not some form of
auto-inclusion macro in the editor?  Why not 'find-replace all' in the
editor?  I can think of a million ways which satisfy the 'lack' of a
well-supported inclusion element in HTML.  And, they work right now.

> inclusion on server side is out of control of page developers unless
they own
> the server, since it depends on which web server product the server
is based.

Why is it always out of the control of the 'page developers'?  That is
nothing more than a defense for poor administrators.  In the case of a
business or some other entity, the lack of proper system
administration should be pointed out to whomever is in charge of the
project.  There are no valid security or performance concerns provided
proper administration of the system.  As for not having control
because of a web host; there are hundreds of web hosts which will give
you vast control of a machine (securely and efficiently) for very
reasonable fees.  Normally tens of times less expensive than the ones
who give you nothing more than FTP access.

HTML is not a programming, scripting, nor all-purpose language.  It is
a simple text markup language and it should be treated as such.  My
opinion (and I'm not alone) is that each object should be returned to
the browser in whole.  A whole document, a whole picture, etc.  I
don't see the advantage of returning a document with various
paragraphs omitted and referenced via some other resource name.  They
are scarcely resources if they are fragmenting across the network.

> Not all servers support .shtml files.

SSI is often ignored for good reason as it is a hacked up mess.  There
are plenty of tools to properly perform all sorts of server tasks.
Most or all of which are widely used, supported, and usually free.
And, there is no good reason why they can't be used.

> Similarly, IFRAME is not supported but a
> lot of browsers, and you cannot rely on pages that are visible
correctly only if

And, INCLUDE is widely supported?  Realistically, no 'major' browser
will ever fully support an INCLUDE-like structure as long as the
company writing it sells server and editor software which does the
same thing and better.  That is where the term 'standards-based
technology' comes into play.  Not exactly the same as
'standards-compliant technology'.

,David Norris

World Wide Web - http://www.webaugur.com/dave
Page via mail - 412039@pager.mirabilis.com
ICQ Universal Internet Number - 412039
E-Mail - dave@webaugur.com

Received on Friday, 1 October 1999 16:42:19 UTC