-
Sep 1st, 2003, 08:33 AM
#1
Thread Starter
New Member
#include directive does not work in HTML
Hi,
I need to call Html file from another HTML file. To accomplish this I use Include tag as:
<!-- include file ="file:///E|/vb/vbToweb/test2.html" -->
but this doesn't work in both browsers IE and netscape
Early response will be highly appreciated.
Thanks,
Hina
-
Sep 1st, 2003, 09:46 AM
#2
Fanatic Member
The #include directive only works server side. The best way to accomplish what you need is to use ASP or JSP. The only way I know of to include any other file for you HTML page is with JavaScript. For Example:
Code:
<script language="JavaScript" src="scripts/main.js"></script>
Then you can call functions that are in that JS file to build sections of your page.
www.RealisticGraphics.net
Running VS.Net Enterprise & VB 6
Other Languages: JavaScript, VBScript, VBA, HTML, CSS, ASP, SQL, XML
MSN Messenger: kmsheff
-
Sep 1st, 2003, 01:47 PM
#3
You can use Frames or the iFrame, the iFrame might behave oddly with different browsers though.
-
Sep 1st, 2003, 01:48 PM
#4
Stuck in the 80s
The server must suppor SSI (server-side includes), and the file must have a .shtml (I think) extension.
-
Sep 2nd, 2003, 05:18 AM
#5
Thread Starter
New Member
Thanks
Thanks all of you
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|