/    Sign up×
Community /Pin to ProfileBookmark

Using UL class – two bullets appear in one line

Hi,

I’m trying to use the instructions [URL=”http://css.maxdesign.com.au/listutorial/master.htm”] here[/URL] to create a ul list type with orange bullets. I also have a UL with blue bullets. (Background is I just inherited this site, blue bullets are from previous admin)

There are two problems. The biggest is that both the blue and the orange bullets show up when I use the orange bullet UL class. The second is that I can’t seem to get the spacing to work from the instructions in the link above so the orange bullet appears in the middle of the text.

CSS:
ul {
list-style-image: url(“bluebullet.png”);
}

ul.smallorng
{
list-style-type: none;
padding: 0;
margin: 0;
}

.smallorng li
{
background-image: url(“smallorangebullet.png”);
background-repeat: no-repeat;
background-position: 1 em;
padding-left: 20 em;
}

HTML:
<ul class=”smallorng”>
<li>item 1</li>
<li>item 2</li>
</ul>

to post a comment
CSS

2 Comments(s)

Copy linkTweet thisAlerts:
@cbVisionJul 15.2013 — It's hard to troubleshoot without having the images, but if you just want orange bullets, you can try this simple trick:

http://jsfiddle.net/u7quB/

(as long as you can change the HTML)
Copy linkTweet thisAlerts:
@s90Jul 19.2013 — PCVC,

If I understand correctly, I think you're problem here is that you're applying the orange background to the list item, rather than the UL list style type - that's why the orange bullet is appearing in the middle of the text.

Try this instead:

ul {

list-style-image: url("bluebullet.png");

padding: 0;

margin: 0;

}

ul.smallorng {

list-style-image: url("smallorangebullet.png");

}
×

Success!

Help @PCVC spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.16,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @nearjob,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...