kettlepot
kettlepot

Reputation: 11011

Crossbrowser way to wrap <li> element around content?

I'm having some problems with the dropdown menu on the page http://grantkot.com/new. If you move your mouse over the elements which have a dropdown menu assigned, you'll see that some of the elements in the dropdown often take more than 1 line and have different widths.

What I'd like it to do is to resize all the <li> of the dropdown menu so that none of them goes to a new line and all the <li> keep the same width and steps don't appear.

How can that be done?

Upvotes: 1

Views: 884

Answers (2)

reisio
reisio

Reputation: 3242

.menu li li a { white-space: pre; }

Upvotes: 2

Damien Pirsy
Damien Pirsy

Reputation: 25445

You might give them a fixed height, otherwise they will change accordingly to their content..Either you resize the content to fit in one line, or you resize the <li>, which will cause those with a one-line contet to have a bigger space around them...

Upvotes: 2

Related Questions