Skip to main content

12th HSC for 2020 and 2021 batch CS HTML colors . Part 2

 HTML COLORS

• Colors are very important to give a good look and feel to your website.

• HTML Color Coding Methods:

• There are following three different methods to set colors in your web 

page −

• Color names − You can specify color names directly like green, blue 

or red.

• Hex codes − A six-digit code representing the amount of red, green, 

and blue that makes up the color..

• Color decimal or percentage values − This value is specified using 

the rgb( ) property.


HERE ARE THE EXAMPLES TO SET BACKGROUND

OF AN HTML TAG BY COLOR NAME

<html>

<head>

<title></title>

</head>

<body bgcolor=“ red”>

</body>

</html>


HTML COLORS - HEX CODES

• A hexadecimal is a 6 digit representation of a color.

• The first two digits(RR) represent a red value, the next two are a green value(GG), and 

the last are the blue value(BB).

• Each hexadecimal code will be preceded by a pound or hash sign #. Following is a list of 

few colors using hexadecimal notation

• #000000 -→ black color.

• #FF0000→red

• #00FF00→green

• #0000FF→blue



RGB COLOR CODING IN HTML

• An RGB color values is specified with rgb(red, green, blue ).

• Each parameter define the intensity of color 

• The intensity of color vary from 0 to 255.

• For example : rgb(0 , 0 , 255) → blue color.

• <style>

div{ 

Color: rgb( 0, 191, 255);

</style>.

Comments

Popular posts from this blog

Free notes of Biomolecules short revision part 1

Biomolecules Polysaccharide are not sweet in taste.               All monosaccharides are reducing sugar.         Monosaccharides are starting from carbon number 3.                                                                Starch contain amylose and amylopectin amylose contain bonding between c1 -c4 and amylopectin has c1-c6 bonding in their structure.                                                                 Monomers: a)Lactose : 1) beta -D galactose 2)beta - D glucose.                                   ...

Free notes of surface tension

  Surface tension.         Intermolecular forces:- The forces of attraction and repulsion between their molecules . These forces ,are called intermolecular . Their is to forces 1) cohesive force.  2) adhesive force. Cohesive force:- the force of attraction between 2 molecules of same substance called as cohesion. Adhesive force:- the force of attraction and repulsion between the two different substance like liquid and solid ,solid with gas etc. is called adhesion. Range of molecular forces:- The maximum distance between 2 molecules upto which intermolecular forces are effective (also called as short range forces). Distance (10 to the power -9). Sphere of influence :- an imaginary sphere drawn with given molecule as centre and radius equal to the molecular range . Surface film :- The layer of surface of liquid whose thickness is about equal to range of molecular attraction. Surface energy :- when a molecular is taken from the inside to the surface layer work...

Free notes of Biomolecules short revision part 2

  Biomolecules part 2. DNA has bases like adenine , gunine , cytosine , thymine.                                                  RNA has bases like adenine, gunine , cytosine , urasil.                                                        Adenine have hydrogen bond with thymine and cytosine have hydrogen bond with gunine.                                                                       D- fructose , D - manose ,D- glucose , form a same osazone product .                        ...