469,658 Members | 1,816 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,658 developers. It's quick & easy.

Includes files in HTML

Hi,

I am having problems having an include file rendered in my browser
(IE6).

The include file contains <A href> tags to be used as a navigation bar
in the footer of a .html file.

I am using dreamweaver and the included html appears as expected in
the 'Design View' but does not get rendered in the browser.

The code I am using looks like this:

<TD>
<!--#include file="includes/navbar.html" -->
</TD>
Jul 20 '05 #1
9 2487
Sometime around 20 Nov 2003 18:28:41 -0800, Adam is reported to have
stated:
Hi,

I am having problems having an include file rendered in my browser
<snip>
<TD>
<!--#include file="includes/navbar.html" -->
</TD>


Does your host support SSI? Even if they do, the file may need to be
renamed to navbar.shtml, depending on the server configuration.

--
Mark Parnell
http://www.clarkecomputers.com.au
Jul 20 '05 #2
ar********@hotmail.com (Adam) wrote in message news:<a8**************************@posting.google. com>...
I am having problems having an include file rendered in my browser
(IE6).
I am using dreamweaver and the included html appears as expected in
the 'Design View' but does not get rendered in the browser.


Are you viewing this page locally? Because it's the server, not the
browser, that does the include. (I presume Dreamweaver processes the
SSI in order to give a proper preview.)

--- Stephen Morley ---
http://www.safalra.com
Jul 20 '05 #3
Mark Parnell wrote:
Sometime around 20 Nov 2003 18:28:41 -0800, Adam is reported to have
stated:
Hi,

I am having problems having an include file rendered in my browser

<snip>

<TD>
<!--#include file="includes/navbar.html" -->
</TD>


Does your host support SSI? Even if they do, the file may need to be
renamed to navbar.shtml, depending on the server configuration.


Are you sure? It's been a long time since, but ISTR that it's the parent
that had to have the .shtml extension - in some environments etc ...

--
William Tasso - http://WilliamTasso.com
Jul 20 '05 #4
Sometime around Sun, 23 Nov 2003 23:59:49 -0000, William Tasso is reported
to have stated:

Are you sure? It's been a long time since, but ISTR that it's the parent
that had to have the .shtml extension - in some environments etc ...


I thought I was. :-) But you could be right. It's never been an issue for
me, so I've never needed to know.

--
Mark Parnell
http://www.clarkecomputers.com.au
Jul 20 '05 #5
Mark Parnell wrote:
Sun, 23 Nov 2003 23:59:49 -0000, William Tasso is reported to have
stated:
ISTR that it's the parent that had to have the .shtml extension -
in some environments etc ...


I thought I was. :-) But you could be right. It's never been an
issue for me, so I've never needed to know.


The document that contains the ssi directive is the one that matters.
It is usually the case that the document with the ssi directives must
have a special extension, often .shtml instead of .html, but one could
set up a server to look for and process ssi in documents with any
extension, including .html.

--
Brian
follow the directions in my address to email me

Jul 20 '05 #6
Just a follow-up question. It's been years since I used HTML, but
it's never too late to get back into the game. Excuse my ignorance on
the following. I was thinking of using the #include command also to
eliminate redundant code (ex; navigation bar etc. on multiple pages)
on a site I am developing and the whole.....making sure the server
option is on is a bit confusing. What if I am using my PC as the
server? Can I test includes on my PC... Why won;t my includes
work....Do I need to use the secret password abracadabra??? I'm lost
on the background here and some fundamentals. Care to elaborate a
bit?

Thanks in advance for your clarification.

Mark.
Jul 20 '05 #7
ms*******@comcast.net (Mark) wrote in
news:68**************************@posting.google.c om:
Just a follow-up question. It's been years since I used HTML, but
it's never too late to get back into the game. Excuse my ignorance on
the following. I was thinking of using the #include command also to
eliminate redundant code (ex; navigation bar etc. on multiple pages)
on a site I am developing and the whole.....making sure the server
option is on is a bit confusing. What if I am using my PC as the
server? Can I test includes on my PC... Why won;t my includes
work....Do I need to use the secret password abracadabra??? I'm lost
on the background here and some fundamentals. Care to elaborate a
bit?


In order to use server-side includes on your local PC, you'll have to
install and use some server software that interprets includes. I'd suggest
Apache (you can set it up so it doesn't accept requests from anything non-
local). You can find versions for most any OS.

Jul 20 '05 #8
Sometime around 25 Nov 2003 21:23:03 -0800, Mark is reported to have
stated:
Can I test includes on my PC... Why won;t my includes
work....
You need to have a server (e.g. Apache, IIS) running on your computer.
Do I need to use the secret password abracadabra???


Yes, but that's not the password. ;-)

--
Mark Parnell
http://www.clarkecomputers.com.au
Jul 20 '05 #9
us****@safalra.com (Safalra) wrote in message news:<c5**************************@posting.google. com>...
ar********@hotmail.com (Adam) wrote in message news:<a8**************************@posting.google. com>...
I am having problems having an include file rendered in my browser
(IE6).
I am using dreamweaver and the included html appears as expected in
the 'Design View' but does not get rendered in the browser.


Are you viewing this page locally? Because it's the server, not the
browser, that does the include. (I presume Dreamweaver processes the
SSI in order to give a proper preview.)

--- Stephen Morley ---
http://www.safalra.com


Renaming the include file to have a *.shtml extenstion didnt help.
The page containing the include is a .html and running on IIS.
The same include statement works when calling from with a .asp page
but not when calling from a .html page.

Thanks,
Adam
Jul 20 '05 #10

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

13 posts views Thread by Tim Tyler | last post: by
25 posts views Thread by Martin Walke | last post: by
8 posts views Thread by Jim | last post: by
12 posts views Thread by tshad | last post: by
6 posts views Thread by William F. Zachmann | last post: by
1 post views Thread by Martin Olson | last post: by
7 posts views Thread by McKirahan | last post: by
4 posts views Thread by Ron | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.