Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

CSS:  define color swatch names?

Posted on 2012-03-12
4
Medium Priority
?
359 Views
Last Modified: 2012-03-12
In graphic design tools, there are not only character & paragraph styles, but ink swatch definitions to use a certain color in many contexts.

I'm wondering if there's an equivalent to define a color and then be able to use it in CSS rule definitions wherever  (text, background, etc.) colors are to be specified, rather than having to paste in a #literal.

thanks
0
Comment
Question by:willsherwood
  • 2
  • 2
4 Comments
 
LVL 84

Expert Comment

by:Dave Baldwin
ID: 37711439
Here are the predefined color names: http://www.w3schools.com/cssref/css_colornames.asp
0
 

Author Comment

by:willsherwood
ID: 37711811
thanks - i'm familiar with color names,
sorry i didn't clarify that i'm looking to define CUSTOM colors
0
 
LVL 84

Accepted Solution

by:
Dave Baldwin earned 2000 total points
ID: 37711894
In that case, your server side language or development tool would have to support that.  CSS doesn't have any programming functions.  It is strictly style definitions.
0
 

Author Closing Comment

by:willsherwood
ID: 37712031
thanks
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When applying CSS to your HTML, there are many different ways to select which element(s) the CSS applies to.  Some of these selectors are more commonly known and used than others - Here are the more common ones: #X - Matches an ID of X .X - Matche…
Introduction A frequently asked question goes something like this:  "I am running a long process in the background and I want to alert my client when the process finishes.  How can I send a message to the browser?"  Unfortunately, the short answer…
In this tutorial viewers will learn how add a full-size background image to a webpage using CSS3. Create a new HTML document with an internal stylesheet.: In CSS, define the html element to have a background image. Use a high resolution image.: In t…
In this tutorial viewers will learn how to style a decorative dropcap for the first letter in a paragraph using CSS. In CSS, create a new paragraph class by typing "p.fancy": Then, to style only the first letter of the first sentence, include the ps…
Suggested Courses

824 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question