Techheadz Tips and Tutorials
Xilo Reseller Webhosting
Enter Search Term
ID: 157 Category: CSS Date Posted: 19/02/2010 Page Impressions : 1,036
0
Print Create a css background using a gif, png

Create a css background using a gif, png

To create a css background that is centered, and fills the height of the screen 100% in all browsers, create your gif or png image.

After this copy and paste the code below in to your stylesheet. Change the URL of the image to the same name as you saved your image as.

/* CSS Document */
body {
background-image: url(my_image_name);
background-repeat:repeat -y;
background-position:center;
margin-top:0px;
}

If you create your background as .png, you can then add shadows to it, which creates a really great effect.

Please take a look at the link below to see the type of effect that can be achieved.


Related CSS Links

http://creativecakesbyjanie.co.uk/




 
Visit OSDisc for Linux & BSD Disks
Home | About | Links | Add Your Link | Most Popular | Last Accessed | Twitter | Site Map
Apache | CSS | HTML | Javascript | Linux |MySQL | Perl | PHP | Linux News & Games | Retro Computing | Ubuntu | Mint | Kubuntu | Win