Milonic provide full featured pull down web menus for some of the worlds largest companies
click here to see what it can do for you

Download Milonic DHTML Menu
Buy Milonic DHTML Menu

Back To Start Of Archive
Taken From The Forum: Archived Topics for the old Version 3.0 JavaScript Menu
Forum Topic: Click to view post
Last Updated: Saturday July 14 2012 - 06:07:34

Can you link to/back from pages in different folders?


Poster: #psyickphuk
Dated: Monday February 17 2003 - 13:20:23 GMT

Using the same menu_array.js?

I ask because I have all my content pages in a subfolder, with my index page in the root (obviously) - I'm having problems because the relative paths change depend on whether the menu_array is loaded into the index page or my content pages. I don't want to use absolute URLs in the form of http://www.mydomain.com/Content/Page1.asp etc because I have two different URLs pointing to the same webspace.

Is there any way around this short of using a different menu_array for my index page?

(I notice that the milonic site has a redirect to /menu/ where all the pages are, mayybe not then)


Poster: kevin3442
Dated: Monday February 17 2003 - 21:23:46 GMT

Hi,

I use relative paths all the time. Sounds like you're making your paths relative to the current page's locaiton, rather than relative to the root of the site or to the server. Are you using a "/" on the front of the path name?

Also, if nothing else, you could define some "root path" string variables and prepend them to the menu items' URLs, like so:
Code:
p1 = "http:/www.mydomain.com/whatever/"

and in the menu item...
Code:
,"Item Text",p1+"subpath/file.html",,,1

If a base path ever needs to change, it's easy; just change the appropriate variable, rather than editing all of the menu entries.

Hope that helps,

Kevin