Color!!!!!!!

Does anyone know how to make backround color on a webpage? :confused: <br />
<br />
Someone once told me but it didn't work. :mad: <br />
<br />
<br />
Please Help :(<!--content-->add the following code in any element for which you want to change a background color<br />
<br />
style="background-color:lightyellow;"<!--content-->Thanks for the effort but it didn't work<!--content-->You did not implement it correctly.<br />
<br />
post your implemented code here<!--content-->I had to read this posting after seeing that many exclamation points!<br />
<br />
With apologies to the CSS drones, you don't have to use CSS to set page background color. Just substitute whatever color you want for "white" in this:<br />
<br />
<body bgcolor="white" text="black" link="blue" vlink="purple" alink="red"><!--content-->I am a firm believer of moderation,however,I'd rather start doing things in a way that will help me in future, and not do things only because it works today, as much as it possible without compromising too much.<br />
yes ofcourse bgcolor can be used as yet,but its deprecated already so I am sure in a year or 2 the page written this way will need upgrading...now would you like to recomend an almost obsolete method to some one who needs help or give them the best possible advice??<br />
<br />
Here is the link at w3c see what they have to say about bgcolor<br />
<!-- m --><a class="postlink" href="http://www.w3.org/TR/html4/present/graphics.html#adef-bgcolor">http://www.w3.org/TR/html4/present/grap ... ef-bgcolor</a><!-- m --><br />
<br />
best choice I'd say is to use style="background-color:lightyellow"<br />
<br />
lightyellow should be replaced with the color of your choice.<!--content-->you don't have to use CSS to set page background colorNo you don't, but background-color is a property that has been supported for a long time now. It is better than to use deprecated HTML.CSS dronesYes. We really shouldn't embrace new technologies. Do away with them all. Back to 8-Track tapes! With apologies to the CD/DVD "drones". ;) :p <br />
<br />
<body style="background-color: silver">And as Khalid already mentioned, this can be applied to any element (a property not shared by the HTML bgcolor attribute).<!--content-->
 
Back
Top