JavaScript is disabled! Please enable JavaScript in your web browser!

Freestyle Academy of Communication Arts & Technology

1299 Bryant Ave, Mt. View, CA 94040 T 650-940-4650 x5090
2 Required Classes: English and Digital Media 3rd/Elective Class:  + Animation or Design or Film

Back to list of all examples

Useful Stuff About:

Background Image Centered

Resize this browser window to see effect of background image that always centers itself. Best practices:

Here's the CSS


body {
background-image:url(../images/Background_Image_Centered.jpg);/*Adjust the path to actual image*/
background-repeat:no-repeat;/*Usually don't want custom background images repeating*/
background-position:top center;/*This ensures the top of the photo is always visible and it REMAINS centered on the page*/
background-color:#000;/*Adjust this color to fit the bottom most layer color or your main background image*/
}