Posts

Showing posts with the label colors

Understanding HTML Colors: names, RGB, HEX

Image
In HTML, colors can be specified in three different ways: by color names, HEX values, or RGB values. Let's delve into each of these methods: Color Names HTML supports 140 standard color names. These color names are case-insensitive and they are easy to understand and use. Here are some examples: <p style="color:Red">This is a red text.</p> <p style="color:Blue">This is a blue text.</p> <p style="color:Green">This is a green text.</p> output: This is a red text. This is a blue text. This is a green text. The drawback with using color names is that your choices are limited to those predefined 140 colors. HEX Values HEX values specify colors using hexadecimal values. A HEX value is a six-digit combination of numbers and letters defined by its mix of red, green, and blue (RGB). Each of the three colors can have values from 00 to FF. For example: ...