HTML Background color in body tag in a page

What should be my background color code of any page? Background color code can be defined in the body tag of the html code. You can see the details of body tag at html code structure. The html code is

<body bgcolor="#ffffff" text="#000000" link="#0000ff" vlink="#800080" alink="#ff0000">

See the code bgcolor="#ffffff" in above body tag. This will make the body background color white as   #ffffff is he hex value of white color. Same way the hex value of any color can be placed in the body tag and the page color can be changed. To get the hex value of of any color you can use html color chat.  

Black background and white font

We will develop a page with black colour background and the text colour should be white. We will also display links on this demo page in red colour. Here is the sample code for this demo. Watch the body tag.
<!doctype html public "-//w3c//dtd html 3.2//en">


<title>This is a demo page to check body background color and text color</title>
<META NAME="DESCRIPTION" CONTENT="Creating a page with black background and white font color">
<META NAME="KEYWORDS" CONTENT="black body Body tag, white font, red link">


<body bgcolor="#000000" text="#ffffff" link="#ff0000" vlink="#800080" alink="#ff0000">

Welcome to <a></a><br>
You are leaning HTML tags here. 

Demo of Black background and white text Table Background image How style CSS is used to manage background color, image
Meta Tags Body tag & background color of the web page
HTML Page Structure


* indicates required
Subscribe to plus2net

    Post your comments , suggestion , error , requirements etc here

    We use cookies to improve your browsing experience. . Learn more
    HTML MySQL PHP JavaScript ASP Photoshop Articles FORUM . Contact us
    ©2000-2024 All rights reserved worldwide Privacy Policy Disclaimer