Issues with jQuery/CSS Nav not hiding and horizontal position -
update: horizontal positioning has been resolved, still having issues menus not disappearing.
updated jsfiddle: http://jsfiddle.net/trevoray/crpdk/7/
i've come across 2 issues nav can't past. can take , me out?
horizontal position. page centered, don't know exact position. made absolute , thought absolute based upon it's parent element, it's not working. need horizontal position same regardless of how wide user's browser is.
menus not "hiding" after onmouseout. can't seem figure out how menus go away consistantly.
here's jsfiddle:
http://jsfiddle.net/trevoray/crpdk/2/
#nav-about { z-index:4000; position:absolute; left:186px; display:none;} #nav-meetings { z-index:4000; position:absolute; left:357px; display:none;} #nav-journal { z-index:4000; position:absolute; left:528px; display:none;} #nav-goodstuff { z-index:4000; position:absolute; left:699px; display:none;} #nav-members { z-index:4000; position:absolute; left:819px; display:none;}
- to position element absolute relative parent. parent element needs
position: relative
<div class="parent"> <div class="absolute"> </div> </div>
.parent { position: relative; } .absolute { position: absolute; top: 10px; right; 20px }
2. you've put onmouseout
handler onto submenus. if leave menu point mouse, nothing happens, if leave submenu, submenu hide.
update
i have created working example now: http://jsfiddle.net/vz7qd/1
things note:
- you don't need javascript. see commented out last css statement. enough, css there no animation when showing. (i find
slidedown
/slideup
nicer default animation ofshow
btw.) - the javascript binding
mouseenter
/mouseleave
handlers top navigationli
element holds submenu. submenu child ofli
item. - i applied background color , gradient applying 1 single gray gradient elements , add border of desired color link element instead of adding gradient area 1 plain color.
- use ids defining custom background colors links in submenus (similar fat bottom border on top menu items)
Comments
Post a Comment