0
How can a change a particular section's background color on a Web page
How do I format my Web page to make different sections have different colours or different background pictures?
3 Respostas
+ 4
For more accuracy:
- background-image:url('path_to/image_file'); --> picture
- background-color:#xxxxxx; --> color ( could be hexa, rgb, rgba or name format )
- background: --> all attributes ( among which color and picture )
And you can use them, as all css, in several ways:
- inline, with the style attribute of the wanted tag to decorate --> <div style="background:yellow;"> ( but it's ugly, don't except in work on progress )
- by targeting the element with a definition inside a <style> tag, or via a linked external css ( <link rel="" href="file.css"> in the <head> )
With the second solution, you can target your particular element using css selectors and associated rules selector: if you don't see what I'm talking about, you'll be advise to go towards the CSS SoloLearn curse :P ( or use the first solution, or go elsewhere learn css ;) )
+ 3
just use the background-image atribute, on the section you want , and in the src you asign the one you want.
0
Thanks guys