Adding another page to a html page

liunx

Guest
Hi, <br />
I have been using cold fusion and if you are not familiar with CF, it's another programming language that deals with MS access and other things and in that code we have <cf template > where you can call in another page to be desplayied in the current page.<br />
It's useful when you have many pages on the web and have a menu bar with many links so you dont have to change everypage if one link changes.<br />
I was wondering if there is a similar way to do the same thing using javascript.<br />
<br />
If you know or if no such thing exists, please reply to this. That'd be great. <br />
<br />
Thank you<br />
Jihae.<!--content-->sounds like that's a similar fuction to teh standard include that you get with ASP and PHP - it just sticks whatever file you want into the current file at that location. Not sure how to do it with java though, but would suggest that you might get more help in the future posting that sort of question in the hava forum - that said, most of the people who look at that booard will probably look here too, so hope someone is along soon to assist!<!--content-->You can do that with plain HTML and an IFRAME for instance. But maybe I'm missing something. :confused:<!--content-->Perhaps you're looking for Server-Side Includes (SSI)? Just put something like this on your pages:<br />
<br />
<!--#include file="nav_menu.txt" --><br />
<br />
...and then create a text file called nav_menu.txt where you write the HTML code that you want on all of your pages (in this case a navigation menu). Just make sure your webhost supports SSI!<br />
<br />
Cheers! :)<br />
<br />
Edit: For this to work, you must save your HTML file with an .shtml extension instead of the usual .html<!--content-->
 
Back
Top