Style Question

Upfront, I’m a newbie.

Hello all,

I’m trying to make an ordered list (ol) and separate each count by, say about 10px.

ie.

  1. Item one

  2. Item two

I was using the <br> tag until I went to validate the page under W3C and it came up with errors. When I tried it the way that the “tidy” showed (…<br /></li>) it wouldn’t work.
I reverted to css and was able to get it to work using this:

#mydiv_id li {
margin-top: 10px;
}

The problem :frowning: is that I can open the file from my hard drive in a browser and it’s fine, but when I upload to the server the effect isn’t there. I hope this is enough info. Any help would be appreciated.

dunno if that would work but u can just try


li {margin: 5px;}

That means that all li tags will have all sides margin 5px, which means margin-top (5) + margin-bottom (5) = 10 :wink:

Just give your li’s a bottom margin 10px and add one extra class for the last li:


li{
    margin-bottom: 10px;
}

li.last{
    margin-bottom: 0;
}

and on your las li apply the class last

Thank you both for your replies.

I modified it a little so that it would not effect my nav links.

li.space {
   margin-bottom: 10px;
   }

li.last {
   margin-bottom: 0;
   }

Thanks so much worked both online and locally.

Regards

That is indeed an option as well :slight_smile: