Aaron Hathaway
Aaron Hathaway

Reputation: 4315

Trouble with div background repeat-x

Hey guys, I feel stupid with this one. I have one <div> that is set to some large width, spanning longer than the window view port and thus adding a horizontal scrollbar. Below that I have another <div>. This <div> has a simple image set as the background-image with repeat-x. I can't seem to get the second <div> to repeat the entire length of the preceding <div>. Take a look here: http://jsfiddle.net/5CW7T/.

Upvotes: 0

Views: 1068

Answers (1)

Sarfraz
Sarfraz

Reputation: 382686

See Example Here


Since your parent div has width set to 2000px, the later should have the same to be as wide as its parent not 100% which fits browser screen.

Upvotes: 3

Related Questions