two diferent bullets
Posted: 05 October 2006 03:43 PM   [ Ignore ]
Newbie
Rank
Total Posts:  8
Joined  2006-09-10

I’ll like help in creating two different UL list items. one an arrow and the other a star. I know this
UL {
  list-style-image: url(products/images/arrow.gif);
  margin-left: 15px;
}

and it gives a nice arrow in my UL, I like to know how to have two different UL using two different images. I am new to CSS so it’s fair to assume I am a rookie

Profile
 
 
Posted: 25 October 2006 02:09 PM   [ Ignore ]   [ # 1 ]
Newbie
Rank
Total Posts:  10
Joined  2006-10-02

The easiest way is to create a base UL style like you have a then two classes for the two different looking lists.


<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Strict//EN” “http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd”>
<html xmlns=“http://www.w3.org/1999/xhtml”>
<head>
<meta http-equiv=“Content-Type” content=“text/html; charset=utf-8” />
<title>UL - Bullet Images</title>
<style type=“text/css” media=“all”>
/* Place styles that you want applied to every ul list here */
ul {
margin-left: 15px;
}
/* Place styles that you want applied only to ul list with the ‘list1’ class */
ul.list1 {
list-style: circle;
}
/* Place styles that you want applied only to ul list with the ‘list2’ class */
ul.list2 {
list-style: disc;
}
</style>
</head>
<body>

<ul class=“list1”>
  <li>Item 1</li>
      <li>Item 2</li>
</ul>

<ul class=“list2”>
  <li>Item 1</li>
  <li>Item 2</li>
</ul>

</body>
</html>

Profile
 
 
Posted: 29 October 2006 06:42 PM   [ Ignore ]   [ # 2 ]
Newbie
Rank
Total Posts:  10
Joined  2006-10-29

sincejan63, you need to read about CSS classes
without classes you can’t take full advantage of CSS

Profile