answersLogoWhite

0


Best Answer

You use the style attribute to add any presentation to your BODY element, including background-color.

This is the code to make an HTML document with a red background.

<body style="background-color: red">

You can also add a stylesheet to the head of the document (or an external file, if you're going to have the same rules on more than 1 page.)

<style type="text/css">

body { background-color: #f00; } /* Short of ff0000 which is hex for "red" */

</style>

User Avatar

Wiki User

12y ago
This answer is:
User Avatar
More answers
User Avatar

Wiki User

12y ago

Add this to your body tag to give the background a solid color. Substitute black for the color of your choosing:

<body style="background-color:black;">

</body>

This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: What attibute you use in the body tag to give the background a solid color?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Continue Learning about Engineering

What is a HTML code for a background on tinierme?

If for an image: &lt;body background="images/background.jpg"&gt; or if for a color: &lt;body bgcolor="#000000"&gt;


What CSS property specifies the background color of a table?

Use the CSS declaration "background-color" For instance... &lt;style type="text/css"&gt; body { background-color: red; } &lt;/style&gt; That code will change the background color to red. Background color will take the same values for a color as all other CSS color. A named color keyword, a hex RGB value, a decimal RGB value, and a decimal RGBA value.


What tag can set the background color for your page?

The BODY tag is the one you should reference if you want to set the background color of the entire webpage, using the bgcolor attribute. For example: &lt;body bgcolor="Blue"&gt; This should be done using CSS. In an internal or external sheet, you want a rule similar to the following: body {background-color: #ff00ff;} If you insist on doing it inline (for whatever reason) you want to attach the STYLE attribute to the BODY tag directly, and use the same rule. &lt;body style="background-color:#f0f;"&gt;


What is the default background color for the canvas element in HTML 5.0?

The default background color for the &lt;canvas&gt; element in HTML5 is the same as the browser default background color. If there is a style sheet or &lt;body&gt; tag that defines the color, &lt;canvas&gt; will inherited that color. You can add style attributes to the &lt;canvas&gt; tag to set a different default background color for the element.


What CSS would apply a blue color to a web page background?

You have two options. 1. Set the body tag to the specified blue color: &lt;body style='background-color: #0000FF'&gt; (Find the colors and their corresponding codes using a search engine. #0000FF is a bright blue) 2. Create an image 1 pixel by 1 pixel of the blue color you want to use. Set the body tag to display that image: &lt;body style='background-image: url("myBlueImage.gif")'&gt; I have used the inline styles. You could do this using a linked sheet, or the &lt;STYLE&gt; tag in the header or your HTML. 1. BODY { background-color: #0000FF; background-image: url("myBlueImage.gif"); }

Related questions

How do I get a background for Veoh?

1. Click your account name on the top right. 2. On top of your image, click the button [edit] 3. Scroll down to the bottom of the page. 4. input this code in the "Custom CSS" box: body { color: #006699; background-image:url(static.flickr.com... background-position:Top Left; background-attachment:...; background-repeat:repeat; font-family: arial;} .sectionBody { border-left: 1px solid #006699; border-right: 1px solid #006699; border-bottom: 1px solid #006699; background-color: #FFFFFF;} .sectionHeader { background-image: none; background-color: #FFFFFF; color: #006699; height: 20px; font-weight: bold; font-size: 14px; padding-left: 8px; border-left: 1px solid #006699; border-right: 1px solid #006699; border-top: 1px solid #006699;} .labelText { color: #006699; } .userThumb { border: 1px solid #006699; } .videoActionBlock { border: 1px solid #006699; background-color:#FFFFFF; color: #006699; } .videoActionBlockText { color: #e26fab;} .bigText { color: #006699; font-family: Trebuchet MS; font-size:48px;} --- there you have it. -------------------------------- To make your own BG do this: look up this specific code: background-image:url(--) on the 2 -- write in your website image url. you do need the http:// -------------------------------- there you have it.


What is a HTML code for a background on tinierme?

If for an image: &lt;body background="images/background.jpg"&gt; or if for a color: &lt;body bgcolor="#000000"&gt;


Where is the best place to find Fuzz academy layouts?

i don't know but i can gice you one *winks* body { background-color: #40808a; background-image: url(http://i33.photobucket.com/albums/d82/ShamanIn u/Fuzz%20Academy/Choco_Background.jpg); background-position: top left; background-attachment: fixed; background-repeat: repeat; } Body, font, td, div { Color: #422100; Font-family: Tahoma, Lucida Bright, Arial; Font-size: 8pt; } body a:link {Color: 422100; font-size: 9pt; } body a:hover, a:active {Color: 422100; text-decoration: underline; font-size: 9pt; } body a:visited {Color: 422100; text-decoration: strikethrough; font-size: 9pt; } div.page_header{ padding-left: 9px; color: #422100; background-image: url(http://i33.photobucket.com/albums/d82/ShamanIn u/Fuzz%20Academy/Choco_SubHeader.jpg); border-left: 2px solid #666600; border-right: 2px solid #666600; border-top: 2px solid #666600; border-bottom: 2px solid #666600; //background-image: url(http://i33.photobucket.com/albums/d82/ShamanIn u/Fuzz%20Academy/Choco_BehindText.jpg); //background-repeat: repeat; } td.topbar2 { background-color: transparent; background-image: url(http://i33.photobucket.com/albums/d82/ShamanIn u/Fuzz%20Academy/Choco_HeaderL.png); background-position: left; background-repeat: no-repeat; border: 2px solid #666600; border-right: none; } td.topbar2 a:link { Color: #422100; font-size: 10pt; } td.topbar2 a:hover, a:active {Color: #422100;text-decoration: underline; font-size: 10pt; } td.topbar2 a:visited {Color: #422100; text-decoration: strikethrough; font-size: 10pt; } td.topbar2_right { background-color: transparent; background-image: url(http://i33.photobucket.com/albums/d82/ShamanIn u/Fuzz%20Academy/Choco_HeaderR.png); background-position: right; background-repeat: no-repeat; text-align: right; color: #422100; border: 2px solid #666600; border-left: none; } td.topbar2_right a:link {Color: #422100;font-size: 10pt; } td.topbar2_right a:hover, a:active { Color: #422100; text-decoration: underline; font-size: 10pt; } td.topbar2_right a:visited { Color: #422100; text-decoration: strikethrough; font-size: 10pt; } td.menu { background-color: #f8f4ac; background-image: url(http://i33.photobucket.com/albums/d82/ShamanIn u/Fuzz%20Academy/Choco_MidHeader.png); background-position: top left; background-repeat: repeat-x; border: 2px solid #666600; border-top: none; border-bottom: none; } td.menu a:link {Color: #422100; } td.menu a:visited {Color: #422100;text-decoration: strikethrough; } td.menu a:active, a:hover { Color: #422100; text-decoration: underline; } td.shadow { background-color: transparent; background-attachment: none; content: none; display: none; width: 100%; border: none; padding: 0px; } td.profile_comments_img {border: 1px solid #666600; } div.profile_action {border-bottom: 1px solid #666600; } td.profile_friend img {border: 1px solid #666600; } img.photo {border: 1px solid #666600; } td.header { border: 2px solid #666600; border-top: 2px solid #666600; border-left: 2px solid #666600; border-right: 2px solid #666600; color: #422100; background-color: transparent; background-image: url(http://i33.photobucket.com/albums/d82/ShamanIn u/Fuzz%20Academy/Choco_TableHeaders.jpg); background-position: bottom right; background-repeat: repeat; } td.header a:link {Color: #422100; } td.header a:visited {Color: #422100;text-decoration: strikethrough; } td.header a:active, a:hover {Color: #422100;text-decoration: underline; } #flashcontent { background-color:transparent; background-image:url(http://i33.photobucket.com/al bums/d82/ShamanInu/Fuzz%20Academy/Choco_FlashBox.p ng); background-repeat: no-repeat; } td.profile_menu1 a { color: #422100; background-color: transparent; background-image: url(http://i33.photobucket.com/albums/d82/ShamanIn u/Fuzz%20Academy/Choco_VisitorBoxes.png); background-position: right; background-repeat: repeat; border-bottom: 1px solid #666600; } td.profile_menu1 a:hover { color: #422100; background-color: transparent; background-image: url(); background-position: right; background-repeat: repeat; border-bottom: 1px solid #666600; } td.profile { background: transparent; border: 2px solid #666600; border-top: 2px dashed #666600; padding: 5px 7px 5px 7px; margin-bottom: 9px; background-image: url(http://i33.photobucket.com/albums/d82/ShamanIn u/Fuzz%20Academy/Choco_BehindText.jpg); background-position: bottom right; background-repeat: repeat; } td.profile a:link {Color: 422100; font-size: 9pt; } td.profile a:hover, a:active {Color: 422100; text-decoration: underline; font-size: 9pt; } td.profile a:visited {Color: 422100; text-decoration: strikethrough; font-size: 9pt; } td.profile_postcomment { padding: 10px; color: #422100; border: 1px solid #666600; border-top: none; } text.area { border: 1px solid #666600; font-family: arial, verdana, serif; color: #422100; padding-left: 2px; font-size: 9pt; } #comment_body {color: #422100!important;border: 1px solid #666600; } input.button { font-family: arial, verdana, serif; font-size: 9pt; padding: 3px; color: #422100; vertical-align: middle; border-top: 1px solid #666600; border-left: 1px solid #666600; border-bottom: 1px solid #666600; border-right: 1px solid #666600; } td.content { vertical-align: top; text-align: left; padding: 0px; background-color: transparent; background-image: url(); } div.profile_blogentry {font-color: #422100; } div.profile_blogentry_date {color: #422100; } div.profile_action_date {color: #422100; } td.profile_postcomment { background-color: transparent; background-image: url(http://i33.photobucket.com/albums/d82/ShamanIn u/Fuzz%20Academy/Choco_BehindText.jpg); background-position: top right; background-repeat: repeat; color: #422100; border: 2px solid #666600; border-top: 2px dashed #666600; border-left: 2px solid #666600; border-right: 2px solid #666600; } td.profile_comment_body { background-color: transparent; background-image: url(http://i33.photobucket.com/albums/d82/ShamanIn u/Fuzz%20Academy/Vex_CommentArea2.png); background-repeat: repeat; border: 1px solid #666600; border-top: 1px dashed #666600; border-left: none; border-right: none; } td.profile_comment_author { background-color: transparent; background-image: url(http://i33.photobucket.com/albums/d82/ShamanIn u/Fuzz%20Academy/Vex_CommentArea2.png); background-repeat: repeat; border: 1px solid #666600; border-right: none; border-left: none; border-bottom: none; } input.button, textarea { background-color: transparent; background-image: url(http://i33.photobucket.com/albums/d82/ShamanIn u/Fuzz%20Academy/Vex_CommentArea2.png); background-repeat: repeat; color: #422100; font-size: 9pt; } div.ad_bottom { background-image: url(http://i33.photobucket.com/albums/d82/ShamanIn u/Fuzz%20Academy/Choco_AussieTag.png); background-color: transparent; background-position: center center; background-repeat: no-repeat; height:80px; } yourwelcome


What CSS property specifies the background color of a table?

Use the CSS declaration "background-color" For instance... &lt;style type="text/css"&gt; body { background-color: red; } &lt;/style&gt; That code will change the background color to red. Background color will take the same values for a color as all other CSS color. A named color keyword, a hex RGB value, a decimal RGB value, and a decimal RGBA value.


What tag can set the background color for your page?

The BODY tag is the one you should reference if you want to set the background color of the entire webpage, using the bgcolor attribute. For example: &lt;body bgcolor="Blue"&gt; This should be done using CSS. In an internal or external sheet, you want a rule similar to the following: body {background-color: #ff00ff;} If you insist on doing it inline (for whatever reason) you want to attach the STYLE attribute to the BODY tag directly, and use the same rule. &lt;body style="background-color:#f0f;"&gt;


What is the default background color for the canvas element in HTML 5.0?

The default background color for the &lt;canvas&gt; element in HTML5 is the same as the browser default background color. If there is a style sheet or &lt;body&gt; tag that defines the color, &lt;canvas&gt; will inherited that color. You can add style attributes to the &lt;canvas&gt; tag to set a different default background color for the element.


What CSS would apply a blue color to a web page background?

You have two options. 1. Set the body tag to the specified blue color: &lt;body style='background-color: #0000FF'&gt; (Find the colors and their corresponding codes using a search engine. #0000FF is a bright blue) 2. Create an image 1 pixel by 1 pixel of the blue color you want to use. Set the body tag to display that image: &lt;body style='background-image: url("myBlueImage.gif")'&gt; I have used the inline styles. You could do this using a linked sheet, or the &lt;STYLE&gt; tag in the header or your HTML. 1. BODY { background-color: #0000FF; background-image: url("myBlueImage.gif"); }


What is a CSS code that can be used to make the background of a homepage on a webs.com website plain black?

body {background-color: black}


What is the background code for a HTML document?

A background can be added on CSS. ex: #body {background: url(../images/bodybg.jpg) repeat-x;}The HTML code for background color is Note: The code must be put inside the body tag, that is between and of your HTML script and the values of color can be change accordingly. For example, if you want to put gray background color you simply change the value to "#727272" or "#000000" for black if you want.


How to register in Friendster?

- Open "Edit Profile" - Select "Customize" - At Customize CSS just fill this :body { background-image: url(your image url); background-attachment: fixed; background-position: top center; background-repeat: no-repeat; background-color: transparent; cursor: ; } example :body { background-image: url(http:/www.de-angel.com/Friendster/FS.GIF); background-attachment: fixed; background-position: top center; background-repeat: no-repeat; background-color: transparent; cursor: ; }


How do you write the CSS and HTML code for an embedded style sheet that configures a background color of?

&lt;style type="text/css" media=screen&gt; body{ background-color: gray;} &lt;/style&gt;


How do you put color on background for websites?

This is the HTML tag: &lt;body bgcolor="green"&gt; or you can use codes &lt;body bgcolor="#00FF00"&gt;