Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CSS Bullet

Status
Not open for further replies.

gokeeffe

Programmer
Jan 11, 2005
170
IE
Hi,

I'm using the following css code.

With this code i have a div box with text inside,

with each point having a bullet image before the sentence.

Is there anyway to alter the position of the bullet, ie

push it left more. Is it possible to control it's position.

Tks


-------------------CSS Code----------------------

#input_rules{
margin-left:100px;
margin-right:100px;
padding-right:20px;
border: 1px dashed #284279;
background-color:#F7F7F7;
}

#input_rules p {
line height: 1.8em;
color:#000066;
font: normal 0.75em arial;
text-align:left;
}


#input_rules ul {
list-style-image: url(includes/bullet.gif);
}


--------------------HTML Code----------------------

<div id = "input_rules">
<ul>
<ol>
<li><p><font size="+1">&nbsp;Username:</font>&nbsp; Use only letters, numbers, and the underscore. Must be between 4 and 20 characters long.</p></li>
<li><p><font size="+1">&nbsp;Email:</font>&nbsp;Must be a valid email address</p></li>
<li><p><font size="+1">&nbsp;Password:</font>&nbsp; Use only letters and numbers must be between 4 and 20 characters long</p></li>
<li><p><font size="+2">&nbsp;*</font>&nbsp;&nbsp;Represents a required field</p></li>
</ol>
</ul>
</div>
 
Something like this:

Code:
#input_rules ul {
    list-style: square inside url(includes/bullet.gif);
}
or
Code:
#input_rules ul {
    list-style: square outside url(includes/bullet.gif);
}
or my preference:
Code:
#input_rules li {
    list-style: none;
    background: transparent url(includes/bullet.gif) no-repeat center left;
    text-indent: 5px;
}

*cLFlaVA
----------------------------
[tt]tastes great, less filling.[/tt]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top