wyc
wyc

Reputation: 55273

CSS background with 2 colors which expand themselves to their sides?

The following page has white (left) and dark gray (right) background. I checked the CSS and it has a white background image and color: #FFF. I can't figure out how did he archived that.

How to do that?

http://www.voceantica.com/

(If you enlarge the web browser both colors enlarge themselves too.)

Upvotes: 1

Views: 1052

Answers (4)

user255631
user255631

Reputation: 345

It will work perfectly fine at any resolution.

body{
    background:url("img/home_page_bg.gif") repeat scroll center top #fff;
    }

Upvotes: 0

Kyle
Kyle

Reputation: 67194

It's done with a really long BG image. Set that as the html background and position your divs accordingly :)

html {
background:#FFFFFF url(images/bg.gif) repeat scroll center top;
text-align:center;
}

Upvotes: 1

Richard
Richard

Reputation: 1289

He has a huge backgroundimage on the html tag:

html {
  background: url("images/bg.gif") repeat scroll center top #FFFFFF;
}

Check the image:

http://www.voceantica.com/wp-content/themes/tao/images/bg.gif

Upvotes: 1

Jusso
Jusso

Reputation: 121

The background gif is 3000px wide. Half white, half dark grey.

Upvotes: 0

Related Questions