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: Help & Support for DHTML Menu Version 5+
Forum Topic: Click to view post
Last Updated: Saturday July 14 2012 - 06:07:31

Child Folder doesn't display images or links properly


Poster: webmaster
Dated: Friday September 23 2005 - 14:44:55 BST

Hi Guys,

I have encountered another problem. It might be me, but I can't find the error. The *.js files work perfectly when they are run in the home directory. Once I add webpages into a child (sub) directory and change the script to "../scripts/menu_data.js" the images don't appear on that particular page.

Also I noticed that the hyperlink to each item lists the folder /Links/.... in front of each link. Very interesting

Your help would be much appreciated, like always.

You can find the page I am talking about at
http://www.worldsplayground.com/TESTSIT ... puters.htm

The pages in the home directory that do work can be found at
http://www.worldsplayground.com/TESTSITE/index.htm

and finally the scripts can be found at
http://www.worldsplayground.com/TESTSITE/scripts/...


Poster: stuart
Dated: Friday September 23 2005 - 20:06:55 BST

Steve

I can't get to your script files so I can't be sure.

My understanding is (and I could be wrong) that the reference you place your page to the *.js file is like an include statement. So it's just like the the text in the *.js file were written in you web page.
Therefore the references to the image files (if you use relative style references e.g. images/myimage.gif) you are wanting will be relative to the web page.
On the pages in the sub directory the relative referrnce is not valid hence no image
I had a similar problem on my site and the only solution I could come up with was to explicitly reference the image files e.g.
Code:
http://www.mysite/images/myimage.gif

If I'm completely wrong (or even partially) I hope someone will correct me as if there is a better solution I'd like to know.
In the mean time explicit referencing should get you up and running

Stuart

Still not working!


Poster: webmaster
Dated: Saturday September 24 2005 - 0:38:36 BST

Thanks Stuart. I tried the absolute reference and I still have the same problem.

Not sure why you couldn't access the scripts. Try http://www.worldsplayground.com/TESTSIT ... nu_data.js

The other *.js files are in the same directory. Just change the file name to open them up.

Images not appearing on child menus


Poster: pdof __at__ earthlink.net
Dated: Monday October 3 2005 - 13:48:18 BST

Steve,

Did you get a fix to this problem? I have EXACTLY the same issue, but I think the way you described it is much better than my description.

I read the one response to your post (using absolute URLs for the images) and I tried it, but that didn't work for me, either.

If you've found a solution, I'd love to hear it... please let me know by posting here (PM has been disabled).

Thanks!!!

Problem almost solved.


Poster: webmaster
Dated: Monday October 3 2005 - 15:28:17 BST

I discovered that the problem is associated with child folders also known as sub folders. The scripts file doesn't appear to have the ability to reference data beyond one child folder. I didn't actually solve the problem itself, however found an alternative to make it work.

After many experiments with the menus and using a variety of parent menus, the only method that worked, was to convince the javascript that it was still in the home page. I did this by creating a sub folder underneath the sub folder and then copied and pasted the images and the "js" files into a 1 down sub folder in my website. It sounds complicated - but isn't really. Here is an example of what I mean.

[Home Page]
_|__|__|__|
_|__|__|__|_[Sub folder 1]
_|__|__|
_|__|__|_ [Sub folder 2]
_|__|
_|__|_[Sub folder 3]
_|
_|__[scripts folder] This is where the original js and images were located for all folders in my website.

The only method that worked was the following ...

[Home Page]
_|__|__|__|
_|__|__|__|_[Sub folder 1]
_|__|__|________|_[scripts folder for sub folder 1] A copy of the js files and image are pasted into this folder._
_|__|__|
_|__|__|
_|__|__|_ [Sub folder 2]
_|__|
_|__|_[Sub folder 3]
_|
_|__[scripts folder] This is STILL where the original js and images are for pages located in the home directory were located for all folders in my website.

The DHTML Menu is commendable and I absolutely recommend it to everyone. If total perfection existed - then people would be out of a job. Ruth, one of the administrators did tell me that she would bring the issue to the programmers as this small error shouldn't occur though.

Hope that helps. If not, send me a private email and I will send you an example of how I set up our website.


Poster: kendra
Dated: Saturday October 8 2005 - 19:34:47 BST

Dude you need to format your page, it runs all off the screen and the tables are really messed up, when you set your font size to smallest its okay but most ppl dont have that, on the default its bad the text is totally looks wrong, the menu breaks on large.

Also your menu does the same thing, I think you need to use styles for your text and menus and fix that :roll: If you need help just ask, it really can make a difference, and make a great look professional.


Poster: webmaster
Dated: Sunday October 9 2005 - 2:33:26 BST

Thank you for you input, however, when I checked it this morning, I have not encountered the problems you claim. Could you give me the exact URL where it occurs so that I can see the problems and correct them.

The website does use CSS. Out of curiousity what screen resolution are you using?