Padding Color change on rollover?


I am working with the CSS on a wordpress template, and I almost have it looking the way I want - there are dropdown menus, and I can get the menu items to highlight on rollover, but not the entire box (the padding) - is there a way to do this ?

Here is the link:

Thanks !

Awesome thanks guys

I can’t see css atm :stuck_out_tongue:

You need to make the anchor a block.

It was set as a block on line 15 in the dropdown.css

#nav a{

You need to make the anchor a block. Check for an example. I haven’t fixed my template for that page so ignore the php errors.

Remove the 10px top and bottom padding from the LI and move it to the anchor.

#nav li ul a {
padding:10px 0 10px 12px;

You already had the 12px left padding on there so be aware that it is adding to the 12em width.

I cant see your css.
but I am guessing this is what’s missing…
your anchor tag has padding left/right, but not top bottom padding. the space that you see above and below is probably caused by either:

  • padding on the LI
  • margin-top/bottom on the anchor tag

find which one of the the two style rules it is, get rid of that declaration ( not the rule… just the declaration for margin or padding) and add the same value as padding-top/bottom and you should be set

hope that helps