This is a discussion on "CSS li hover." within the Web Page Design section. This forum, and the thread "CSS li hover. are both part of the Design Your Website category.
|
|
|
|
|
![]() |
||
CSS li hover.
|
||
| Notices |
![]() |
|
|
LinkBack | Thread Tools |
|
#1
|
|||
|
|||
|
CSS li hover.
Site; http://www.360sigs.com/360sigslayoutnew/categories.php
Css; http://www.360sigs.com/360sigslayoutnew/style.css Problem CSS;
Hover over the Library part and it only uses the Li hover to cover the font. How can I fix it to ignore the padding and fill the whole box? |
|
|
|
#2
|
||||
|
||||
|
Re: CSS li hover.
Try getting rid of the li padding and setting your anchors to display:block, then adding padding to your anchors.
If I understand you correctly, the reason the whole box is not changing colour is because the anchor is not completely filling the space - the li padding is giving it that 'edge'.
Last Blog Entry: The Google Misconception (Feb 3rd, 2008)
|
|
#3
|
|||
|
|||
|
Re: CSS li hover.
You're right and I knew this, but then the text will touch the border and it looks untidy..
|
|
#4
|
||||
|
||||
|
Re: CSS li hover.
But surely if you set your anchors to block elements, then add padding to them, they'll pad out the li's themselves?
Last Blog Entry: The Google Misconception (Feb 3rd, 2008)
|
|
#5
|
|||
|
|||
|
Re: CSS li hover.
I'm slightly confused now
|
|
#6
|
|||
|
|||
|
Re: CSS li hover.
Not quite. Add some padding to the "a", and take any padding away from the li.
This doesn't belong in the hover style. Apply it to the raw "a": a { display: block; padding; 1em; } |
|
#7
|
|||
|
|||
|
Re: CSS li hover.
That makes all the layout mess up pretty much.
|
|
#8
|
||||
|
||||
|
Re: CSS li hover.
Ok try this
Replace all of this
Last Blog Entry: The Google Misconception (Feb 3rd, 2008)
|
|
#9
|
|||
|
|||
|
Re: CSS li hover.
Hmmm, didn't do anything =/
|
|
#10
|
|||
|
|||
|
Re: CSS li hover.
Any idea?
|
![]() |
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| css hover | alexgeek | Web Page Design | 9 | Aug 2nd, 2007 18:18 |
| hover box gallery | acrikey | Web Page Design | 25 | Jul 19th, 2007 22:39 |
| hii Help with hover | hawashp | Starting Out | 1 | May 13th, 2007 16:35 |
| Javascipt or a:hover??????? | Tom87 | Web Page Design | 20 | Mar 28th, 2007 01:11 |