开发者

how to style margins between items in a <dl> list?

开发者 https://www.devze.com 2022-12-15 10:15 出处:网络
So im integrating this Twitter widget into xhtml. ( http://help.twitter.com/forums/10711/entries/15354 )

So im integrating this Twitter widget into xhtml.

( http://help.twitter.com/forums/10711/entries/15354 )

The code is:

<dl id="twitter_update_list"></dl>

...then a couple lines of javascript.

My problem is that I can't figure out how to get any space between the list items. All i need are a couple br tags in between each item.

Im assumi开发者_如何学编程ng i can css style the dl somehow without conflicting with the already established twitter class?

Any ideas? Just need a solution. Thanks!


Have you tried:

dl#twitter_update_list li {
  // margin, padding, line-height
}

This will apply any rules to all list-items found within #twitter_update_list. I took a look at an example of this widget on http://www.dustindiaz.com/search/?q=from:evan and found only that each tweet is contained within a div having the class twtr-tweet. I'm not sure if that's the standard, or if this is just the way this particular user imlemented this tool. If the former, you wouldn't be styling li elements, you'd be stying:

.twtr-tweet {
  // margin, padding, line-height
}


display:block;padding-top:10px;padding-bottom:10px;

or

display:block;margin-top:10px;margin-bottom:10px;

if I understand the layout correctly... set the size elements to a different size as 10 isn't probably enough.

0

精彩评论

暂无评论...
验证码 换一张
取 消