...

View Full Version : Javascript help please



spickee
06-24-2004, 02:43 PM
Ok guys need a bit of help here.

Redesigning our company website to be a bit friendlier and look nicer and more in line with our new corporate image.

Having a bit of trouble with my Javascripting. ie I haven't got a clue isn't dreamweaver great.

Below are two attemts to achieve the same thing.

http://www.comm-tec.co.uk/newweb2/front.htm
and
http://www.comm-tec.co.uk/Test/main.htm

Now number 1 is done with layers and stuff, but I can't keep the menu extended and on top when I follow it. Problem being there is stuff in the bit on the right that needs to be clickable. So I want the menu to stay on top when active and the right hand side to stay underneath until the menu is gone. Make sense?

Effort 2 was using frame to avoid reloading the menu every time, but I got in even more of a mess with this as I can't get the menu to appear outside of its frame.

The javascript is in http://www.comm-tec.co.uk/Test/mm_menu.js

If anyone has got a spare 10 minutes and can stop me going rapdily bald. Please take a look.

Cheers

Spickee

Acid
06-24-2004, 03:30 PM
Urgh Dreamweaver the personification of evil. Nothing beats hand coding in Notepad.

Anyway im at work right now so I can't go through it properly, and unfortunately some dick ripped the phone line out of my wall so my internet is off till the engineer comes round to rewire my phone jack.

In the mean time I'd suggets you check out http://www.webfx.nu they have some very good menu scripts on there which you might want to take a look at.

spickee
06-24-2004, 05:23 PM
Dreamweaver is the weapon of choice purely for timesaving reasons. I used to handcode everything in notepad, at work I just don't have the time.

I'm sure it's something really fundamentally simple, but not knowing JS I'm stuck.

Thanks for taking a look.

Willy Duitt
06-24-2004, 05:32 PM
Try removing the z-index=2 from your Layer2 division.....

spickee
06-25-2004, 11:18 AM
Sorry if I wasn't clear.

The images on the second layer are clickable to link to another page. What I want is the left hand menu to be on top when it is active and the images to become clickable when the menu is not active.

So if you rollover the menu you can select one of the options. But as soon as the menu collapses back down you can click the images on the right.

Any better.

Willy Duitt
06-25-2004, 11:23 AM
Did you even try my suggestion?
How is the menu going to be on top when you have given the images on the right a higher z-index? Your problem is the menu goes under the images because of this.......

glenngv
06-25-2004, 11:28 AM
It's a z-index problem as Willy pointed out.

Remove it or set to -1.

<div id="Layer2" style="position:absolute; width:704px; height:888px; z-index:2; left: 167px; top: 197px;">

spickee
06-28-2004, 09:48 AM
Ok changed the zindex as indicated and now you can click on the images on the main body of the page. This is my problem.

http://www.comm-tec.co.uk/newweb2/front1.htm

Getting the menu on top was easy, what I need is the main body part, ie the bit in layer2 to come to the top when the images are rolled over so they can be clicked.

This is what I can't get working. I can keep the menu on top until I roll out of the menu image, then Layer2 comes to the top, I want layer 2 to stay underneath until the menu is no longer active. Then once the menu has collapsed Layer2 is on top so the images can be clicked.

Sorry if I caused confusion



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum