Brilliant html and css

Page 185

M09_BRAN1529_01_SE_C09.QXD:BRILLIANT

Setting background colour (cont.)

30/1/09

10:45

Page 174

Or if you want, you can choose an image and centre it on your page. <style> body {background-color: blanchedalmond; background-image: url(./cyclist27.tiff); backgroundrepeat:no-repeat; backgroundposition: top center;} </style>

Incidentally, note that the way I made the caption stand out in these screen captures is by creating a span element and making its background colour whitesmoke. <span style="font-size:40px; fontfamily:cursive; color:firebrick; background-color: whitesmoke;">image not tiled and centered</span>

174


Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.