473,401 Members | 2,068 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,401 software developers and data experts.

Bullet Colors

Is it possible in lists for the bullet to have a different color than
the text? If so how?
Jul 20 '05 #1
3 4080
Dante <pi******@reno.com> wrote:
Is it possible in lists for the bullet to have a different color than
the text? If so how?


HTML:
<ol>
<li><span>Test</span>
</ol>

CSS:
li
{
color: red;
}

li span
{
color: green;
}
--
Michael Wilcox
mjwilco at yahoo dot com
Essential Tools for the Web Developer - http://mikewilcox.t35.com
Jul 20 '05 #2
pi******@reno.com (Dante) skrev :
Is it possible in lists for the bullet to have a different color than
the text? If so how?


<style type="text/css">
ul {color: red}
..black {color: black}
</style>
</head>
<body>
<ul>
<li><span class="black">one</span></li>
<li><span class="black">two</span></li>
</ul>
--
Knud
Jul 20 '05 #3
pi******@reno.com (Dante) wrote:
Is it possible in lists for the bullet to have a different color than
the text? If so how?


You could use the method with extra <span> in each <li>, as others have
suggested. But it's probably simpler to use images as bullets instead,
using list-style-image. This is more flexible since you can set the
shape too. The drawback is that the image is inevitably in fixed size
in pixels - making lists look a bit odd when the text size is
considerably larger or smaller than the size for which you have
designed the bullet image.

--
Yucca, http://www.cs.tut.fi/~jkorpela/
Jul 20 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

14
by: Gerald S. | last post by:
Hello, I am trying to set the space between the bullet and the first word in a UL, without any luck. My Lists look like: x Item 1 x Item 2 x Item 3
0
by: Nikolaos Giannopoulos | last post by:
I am trying to get bullet images in paragraphs and lists to align properly - so far Moz 1.3 and Opera 6.05 handle both of these cases fine (NOTE: IE5 as expected does not render a bullet in the 1st...
3
by: Peter Schlenker | last post by:
In a navigation panel I try to place a bullet before each entry when the link is hovered at (see http://www.shambhala.de). Mozilla does it like expected, but IE doesn't - any ideas? <a...
1
by: David Bradbury | last post by:
I may be thinking about this the wrong way, but here goes: In my style sheet I've specified that bullet points should use a specific image rather than just be default bullet points. However, at...
8
by: dp | last post by:
Is there anyway to have the bullet color of a <li> be a different color than the text without using an image? dp
7
by: codeslayer | last post by:
Greetings to everyone in ‘forum-land': I have a problem that has plaguing me to no end. It is a CSS-related question, and I have not seen this question posted anywhere in forums or through...
8
by: Udo Marx | last post by:
Hello to ciwas! Is there a way to change the bullet form, color, etc, of the element <li> under<ul> via css? Any reply will be appreciated. -- Freundliche Gruesse, Netzteil - Udo Marx...
13
by: Matt | last post by:
I would like to set the "list-style-type" to be a hyphen (-). How can I accomplish this in a style sheet. I tried list-style-type: hyphen; and list-style-type: dash; but neither worked. I also...
6
by: Nathan Sokalski | last post by:
I am creating a BulletedList and would like to use a - as the bullet. However, I could not find a way to do this using the properties for the BulletedList control. Is there a way to use a specific...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.