Needless to say, there are ways to specify color on a page using cascading style sheets. First, let’s look at how colors are specified using CSS. The two methods available in HTML are also available in CSS. You can specify colors by name or by using a six – digits hexadecimal specification. There are some other options as well. You can specify colors using a three digit hexadecimal number, which is shorthand for cases where both digits in each pair are the same. For example, if the color you’re using is #fffff (white), you can just specify it as # fff. Or, if you want a light blue such as #66ccff, you can specify it as #6CF.
You can also specify colors using decimal values or percentages. For example, #66CCFF can be specified as (102,204, 255) using decimal notation. Or, fi you prefer, using percentages, like this: (40%, 80%, 100%). If you don’t’ want to worry about these alternative methods, that’s fine. You can just use the same ones that you use when specifying colors in HTML.
No comments:
Post a Comment