[web] display: inline . . cant get it to work

This topic is 4444 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

Recommended Posts

Cant get this to work at all. Ive tried putting it into a class and an id but cant get a (ol) to display inline. are there some other ways i can make a list of text which will be links display inline without using tables? Thanks oh im mainly using IE but have moz on just for testing

Share on other sites
Quote:
 Original post by LongIntegerCant get this to work at all. Ive tried putting it into a class and an id but cant get a (ol) to display inline. are there some other ways i can make a list of text which will be links display inline without using tables?Thanksoh im mainly using IE but have moz on just for testing

Have you tried putting it into the <li> tags instead of the <ol> tags?

Share on other sites
Quote:
 Original post by ExcorsOr try putting it on both, instead of instead.

It really depends on the desired behavior. To inline just the elements themselves while maintaining the rest of a list's behavior then keep them in the <li>. If you want the entire control to flow inline with surounding text then you would add it to both.

Just on <li>.

On <li> and <ol>. Then you would probably want to set the padding on the <ol> to 0px as well.

Share on other sites
yeah even declaring al, (li) elements as li {display: inline;} doresnt do anything, they still come out as an ordered list.

my code is like the follows
.nav{ display; inline;}//added this nextli{display: inline;}----------------------------------<ol class="nav"><li>home</li><li>news</li><li>about</li></ol>

is thee something im doing wrong

Share on other sites
Quote:
 .nav{ display; inline;}

That says "display[semicolon]" when it should be "display[colon]". If you fix that, you should get something like this.

If you want to get rid of the gap on the left, it seems you have to do both padding:0 and margin:0 for it to work in most browsers.

Share on other sites
It might also help if you could provide us with a link to see if the problem lies elsewhere.

Share on other sites
sorry that was a typo it was a colon

1. 1
Rutin
43
2. 2
3. 3
4. 4
5. 5

• 10
• 27
• 20
• 9
• 20
• Forum Statistics

• Total Topics
633405
• Total Posts
3011680
• Who's Online (See full list)

There are no registered users currently online

×