View Full Version : RGB & Hex


altpara
02-02-2003, 11:55 AM
Big tip, for those of you who may not know:

I got sick and tired of converting my colours from RGB to their hexadecimal equivalent. I lamented, "Isn't there an easier way?"

Sure, you can use software to convert it for you, but that is still an extra step I find really tedious, particularily if you ever want to tweak your colours.

Then I found out about a CSS value that saves me the trouble.

Example:

color: #000000;

is equal to

color: rgb(0,0,0);

So there it is. No more trying to figure out hex equivalents, you simply type in rgb, then place the RGB values within parenthesis, separated by one comma.

Another example:

color: #ffffff;

is equal to

color: rgb(255,255,255);

:-D