include virtual

L

Lauren

I have a site on a virtual server that uses page includes. I need the web
pages that are in sub-folders to be able to retrieve the top navigation bar
as a page include without having to copy all of my menu bar files to each
sub-folder for it to work. On one of my websites on a different server I
used the "include virtual" script tag to call the page include and it works,
but for some reason it isn't working on my virtual server site.

I thought this might have something to do with Parent Pathing so I had our
Admin turn it on and then off and then on again, but it doesn't seem to help.

Can anyone out there help?


Thanks,

Lauren
 
T

Thomas A. Rowe

If you turn on Parent Path, then you can use Include File not Virtual. If you are using FP
navigation component, then using FP Navigation component will not work.

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
==============================================
If you feel your current issue is a results of installing
a Service Pack or security update, please contact
Microsoft Product Support Services:
http://support.microsoft.com
If the problem can be shown to have been caused by a
security update, then there is usually no charge for the call.
==============================================
 
L

Lauren

I am not using FP navigation component.
We have Parent Path turned off and I am using the script tag...

<!--#include virtual = "intranet/menu/menu2.htm"-->

When I load the page it give the error...
Error: 'Menu' is underdefined

So it finds the menu, but the graphics do not show up.

Note: The menu works on the home page that is using the same menu , the only
difference is that the home page is not in a sub-folder.


Thanks,

Lauren
 
T

Thomas A. Rowe

Then you script needs to be defined in the include page or each page using the include. You may also
need to use absolute URLs to any images or pages. etc.

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
==============================================
If you feel your current issue is a results of installing
a Service Pack or security update, please contact
Microsoft Product Support Services:
http://support.microsoft.com
If the problem can be shown to have been caused by a
security update, then there is usually no charge for the call.
==============================================
 
R

Ronx

Change
<!--#include virtual = "intranet/menu/menu2.htm"-->
to
<!--#include virtual = "/intranet/menu/menu2.htm"-->
especially in pages in the subfolders.
 
L

Lauren

The menu was created in macromedia fireworks. Do I still need to define my
script. If so... how and where.

Remember it works on the home page without doing this.


Thanks,

Lauren
 
T

Thomas A. Rowe

Your script either needs to be in a external .js file which is linked to from every page in the site
that will be using the include file or you must make sure that the include file has the JavaScript
needed in the part of the page that is being included in other pages.

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
==============================================
If you feel your current issue is a results of installing
a Service Pack or security update, please contact
Microsoft Product Support Services:
http://support.microsoft.com
If the problem can be shown to have been caused by a
security update, then there is usually no charge for the call.
==============================================
 
L

Lauren

I changed the script as you said, but I still receive the same error.

Thanks,

Lauren
 
L

Lauren

Again you are awesome!

I had to copy the code from the javascript file and paste it directly into
my include page and make all urls to my image files absolute and it worked!

Thank you so much!


Lauren
 
T

Thomas A. Rowe

You are welcome.

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
==============================================
If you feel your current issue is a results of installing
a Service Pack or security update, please contact
Microsoft Product Support Services:
http://support.microsoft.com
If the problem can be shown to have been caused by a
security update, then there is usually no charge for the call.
==============================================
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top