Jump to content


This topic is now archived and is closed to further replies.


HTML included files

Recommended Posts

I'm trying to create included files for my navigation bar on my website, since I'm changing it often.  I don't have access to the server to configure it, and server-side html includes don't seem to work at all.  I tried using [code]<!--#include FILE="menu.inc" -->[/code] in my main page with the menu bar in b.inc with no results.  I also tried turning it into a .js file with print statements and adding [code]<script src="menu.js" type="text/javascript"> </script>[/code] to my main page, again with no results.  My external stylesheet is working perfectly, and I have some javascript tooltips on the page that also work.  Any advice on what the problem might be and how to fix it?  Thanks!

Share this post

Link to post
Share on other sites
Perhaps try:
[code]<javascript> print myHTMLCode();</script>[/code]
in the body of your html file where you'd like it to be.

Or, you may simply need to add a trigger to run the javascript. Do you have an onLoad event set to run it?

Share this post

Link to post
Share on other sites


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.