Zen Cart Logo
Forums / Templates, Stylesheets, Page Layout / whats wrong with this css for my dropdown menu?

whats wrong with this css for my dropdown menu?

Locked

Views: 1,609

Results 1 to 10 of 10
This thread is locked. New replies are disabled.
27 May 2010, 4:24 AM
#1
1kell avatar

1kell

Zen Follower

Join Date:
Jul 2008
Posts:
151
Plugin Contributions:
0

whats wrong with this css for my dropdown menu?

I've got this in my tpl_modules_categories_tabs.php to do a drop down menu. I am having two problems.

  1. The dropdown menu won't work until you click on a top category, then it starts to work when you hover.

  2. The position of the drop down is not good at all - its supposed to drop down, mine drops to the right of the category.

I have browsed several times on here to try and work it out, and visited several code tutorial sites and I am still stumped.

<style type="text/css"> #navCatTabsDropdown { width:100%; background:#c04edb; float:left; } #navCatTabsDropdown li { float:left; display:inline; vertical-align:middle; background-color: e978be; posotion: relative; } #navCatTabsDropdown li li {float: none;} #navCatTabsDropdown * li ul { visibility:hidden; background-color: #e978be; position:absolute; padding: 0.5em; z-index: 100; } #navCatTabsDropdown * li:hover ul { visibility:visible; color: #ffffff; background-color: #c04edb; border: 0px outset; white-space:nowrap; } </style>
27 May 2010, 7:34 AM
#2
get_em_fast avatar

get_em_fast

Totally Zenned

Join Date:
Dec 2006
Location:
Seligman, MO U.S.A.
Posts:
2,072
Plugin Contributions:
1

Re: whats wrong with this css for my dropdown menu?

Do you have a URL for us?

27 May 2010, 11:40 AM
#3
1kell avatar

1kell

Zen Follower

Join Date:
Jul 2008
Posts:
151
Plugin Contributions:
0

Re: whats wrong with this css for my dropdown menu?

yep i do, its a work in progress but i'll put it on here. the links are deliberately white.

I've managed to sort out the #2 issue of dropdown placement by putting in

#navCatTabsDropdown * li ul
{
float:left;
visibility:hidden;
text-align:left;
position:absolute;
top:15px;
left:0em;
padding: 0em 0.5em 0em 0.5em;
line-height:15pt;
z-index: 100;
}

I would like it to drop a little lower to the bottom of the bar, but when I do that - it dissappears again before you can scroll the mouse onto it.

Still got issue #1 though - hover wont work until you have clicked on a main category.

Please view the problem at miracle baby.co.nz/ estore /index.php?main_page=index&cPath=21_59

27 May 2010, 11:48 AM
#4
1kell avatar

1kell

Zen Follower

Join Date:
Jul 2008
Posts:
151
Plugin Contributions:
0

Re: whats wrong with this css for my dropdown menu?

ps another thing with the z-index, when the menu drops down over the "sort by items starting with" box, the menu dissappears behind that where it overlaps.

27 May 2010, 12:34 PM
#5
1kell avatar

1kell

Zen Follower

Join Date:
Jul 2008
Posts:
151
Plugin Contributions:
0

Re: whats wrong with this css for my dropdown menu?

okay i really thought i had this almost sorted, but navigating using the cattabs menu i have noticed a major bug with breadcrumbs.

It doesn't show where you are in order to category list - its showing link history instead!?:censored::censored:

27 May 2010, 10:54 PM
#6
get_em_fast avatar

get_em_fast

Totally Zenned

Join Date:
Dec 2006
Location:
Seligman, MO U.S.A.
Posts:
2,072
Plugin Contributions:
1

Re: whats wrong with this css for my dropdown menu?

1kell:

okay i really thought i had this almost sorted, but navigating using the cattabs menu i have noticed a major bug with breadcrumbs.

It doesn't show where you are in order to category list - its showing link history instead!?:censored::censored:

kell, There's too many changes to post here, so I'm pm'ing you. And your breadcrumb seems to be keeping up with every change correctly. Maybe you just need to clear your browser's cache?

28 May 2010, 12:38 AM
#7
1kell avatar

1kell

Zen Follower

Join Date:
Jul 2008
Posts:
151
Plugin Contributions:
0

Re: whats wrong with this css for my dropdown menu?

maybe, thanks I pm'd you back, thanks for helping out I have taken it this far but am pretty stuck.

28 May 2010, 12:41 AM
#8
get_em_fast avatar

get_em_fast

Totally Zenned

Join Date:
Dec 2006
Location:
Seligman, MO U.S.A.
Posts:
2,072
Plugin Contributions:
1

Re: whats wrong with this css for my dropdown menu?

Not a problem, kell. That's what we're here for.

28 May 2010, 1:17 AM
#9
1kell avatar

1kell

Zen Follower

Join Date:
Jul 2008
Posts:
151
Plugin Contributions:
0

Re: whats wrong with this css for my dropdown menu?

the breadcrumb is still acting funny.

You choose something in Cat A to look at, then choose something in Cat C to look at, and the breadcrumb trail will show

"Home-Cat A- Cat C Product"

when it should be
Home-Cat C - Cat C Product."

maybe something in the breadcrumb needs to be changed to work with the Cat Tabs dropdown?

28 May 2010, 1:47 AM
#10
get_em_fast avatar

get_em_fast

Totally Zenned

Join Date:
Dec 2006
Location:
Seligman, MO U.S.A.
Posts:
2,072
Plugin Contributions:
1

Re: whats wrong with this css for my dropdown menu?

I see what you mean about the breadcrumbs. Don't know what the problem is with that. Nothing SHOULDN'T need to be changed for it to work correctly.