List image - space before text


/ Published in: CSS
Save to your folder(s)

Using a combination of background and padding styles to modify the way list image styles are applied.


Copy this code and paste it in your HTML
  1. li {
  2. background: url(images/bullet.gif) no-repeat left top;
  3. padding: 3px 0px 3px 10px;
  4. /* reset styles (optional): */
  5. list-style: none;
  6. margin: 0;
  7. }

URL: http://alistapart.com/article/taminglists

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.