Tuesday, December 6, 2011

How can I make my div block background image centered and undetected by the browser's horizontal scroll bar?

I'm building our web page; I already placed the 1320px X 964px background image well. Everything is quiet good but my main content needs a little space downward so I need to place a continues image background by getting a 1320px X 1px from the bottom section of the main body background and repeat it vertically/downwardly. I did it well. I positioned it on center but when I try to open it in to a lower resolution monitor the repeated 1320X1 repeated image goes wrong and the horizontal scroll bar detected it so it appeared. By the way my monitor's resolution is 1280X1024. I want that 1320X1 image as the overflow background which would not affect the resolution whether it's low or high, or wide...and undetected by the horizontal scroll bar. Thanks!|||Resolution is NOT the problem. Whether the browser generates a scrollbar of any kind depends on the size of its Viewport being used to view a web page. A 1320 px wide image is outside the norm anyway. You'll be generating a scrollbar on everyone's browser whose Viewport is smaller that the image size.



You could try adding the following to the CSS:



overflow: hidden;



Choosing Dimensions for Your Web Page Layout:



In Search of the Holy Grail: http://www.alistapart.com/articles/holyg鈥?/a>

http://www.elated.com/articles/choosing-鈥?/a>

How to create flexible sites quickly using standards like CSS and XHTML: http://www.ibm.com/developerworks/web/li鈥?/a>



960 Grid System: http://960.gs/



Care With Font Size: http://www.w3.org/QA/Tips/font-size



Ron

No comments:

Post a Comment