CharlestonImage.com - Fine Art Photography | Website Design
CharlestonImage.com - Fine Art Photography | Website Design
Home  .::.  Anatomy of Design
CSS Tips, Tricks, & Tutorials to
make your website standout.
Anatomy of Design: CSS 101

The Body

Lets start with the CSS declarations for the body:
BODY {
      background-color : #FFFFFF;
      background-image: url(images/Pattern1.gif);
      background-repeat: repeat-y; 
      font-family : Verdana, Geneva, Arial, Helvetica, sans-serif;
      color : #000088;
      margin: 0px; 
      }

Here we tell the browser that the base-background color for this page is white (#FFFFFF).

We advise the browser to load the background-image "Pattern1.gif" that is located in the "images"-folder.

We also declare that this image shall be repeated only along the y-axis [North-South] and not tile over the total background.

Then we set the font-family as "Verdana" and offer a few alternatives should Verdana not be available on the visitor's computer, and declare the text-color of the page in dark blue (#000088), because it is always a good idea to declare a color with a background-color and vice versa.


The last item is to set the margins to zero. This design does not really call for it, but it is useful in other layouts, and  so good to be acquainted with.

Ok, the BODY is set, and now we save that in a blank file, call it "Styles.css" and open a new document, where we call this stylesheet by linking it in the of our HTML document:

<link href="Styles.css" rel="stylesheet" type="text/css">
Previous Entries
Archives
Share/Bookmark This Page Follow CharlestonImage on twitter Become a Fan on Facebook! In Focus - Photography Blog Subscribe via RSS Subscribe By Email
Website Design - Latest Sites
In Focus - Photography Blog
Anatomy of Design: CSS 101

Home Portfolio Edition Prints Website Design In Focus Anatomy of Design About Contact

Hosting provided by Doteasy.com

Privacy Policy Valid HTML
©2005-2010 CharlestonImage.com. All Rights Reserved.

CharlestonImage.com