Saturday, 4 November 2017

Setting Background for a Web page

Setting Background for a Web page

We can make our web page attractive by adding an image in the background or by giving a color to the background.

Attribute are extra bits of information that appear inside tag.

The BGCOLOR Attribute

To add a color to the background of a Web page the BGCOLOR attribute is used. There are predefined colours names that can be assigned to the bgcolor attribute in an HTML document. They are Black, Red, Gray, Blue, Olive, Navy etc.

BGCOLOR Attribute can be assigned by hexadecimal triplet. A hexadecimal triplet is a combination of three colours, namely Red, Green and Blue. In th hexadecimal triplet, there are six digits; the first two digits represent red, the next two green and last two blue, preceded by a hash (#) symbol.

For example

<BODY BGCOLOR = "BLUE">

THIS IS MY FIRST WEB PAGE.
</BODY>

Or

<BODY BGCOLOR = "#1D36F6">

THIS IS MY FIRST WEB PAGE.
</BODY>


Few Hexadecimal Values

Black           #000000
White           #FFFFFF
Red              #FF0000
Green           #00FF00
Blue              #0000FF
Yellow           #FFFF00
Cyan             #00FFFF
Magenta          #FF00FF


Related Posts:

  • MOVING AHEAD WITH HTML MOVING AHEAD WITH HTML  We have learnt about how to create HTML document in NOTEPAD and view it in any web browser. We have also learnt about some tags and attributes of HTML. Let us learn some more HTML codes in this… Read More
  • Setting Background for a Web page Setting Background for a Web page We can make our web page attractive by adding an image in the background or by giving a color to the background. Attribute are extra bits of information that appear inside tag. The BGCOLO… Read More
  • HTML First developed by Tim Berners-Lee in 1990, HTML is short for HyperText Markup Language. HTML is used to create electronic documents (called pages) that are displayed on the World Wide Web. Each page contains a series of con… Read More

0 comments:

Post a Comment

Good Morning Beautiful

Do you know????

Do you know????
/