What is the usual cause of website having a big white space on the right, making the horizontal scroll bar appear.

Check a screen shot of the project Click Here. Sorry no live site for the mean time.

When I use "overflow:hidden" on the div, it will be fixed. But I cannot use that code because it will cut other divs. I also tried "clearfix". Didnt work.

Help

Recommended Answers

All 11 Replies

Without seeing your CSS it is impossible to tell, but make sure you aren't defining widths for your DIVs unless they are defined properly, and check for elements within the DIV which could be causing them to expand.

Yeah, showing us a screenshot of the website and asking us to diagnose the problem is like taking a picture of your car and bringing it to a mechanic.

Thank you for your replies.

Ok, here is the site Click Here

The concern div wrappers are #main-wrap-bottom and #submain-wrap.

What do you think?

From my browsers.. IE9, Chrome 24.. I did not see a horizontal bar as shown in the pic above.

The reason for that be the div size greater than the page and it results in scroll bar.If you do overflow:hidden ,it will not fix error,but just hide it.
So better fix the size of your container.
I can't see the problem in your site so can't tell the exact fix for it.

Works fine for me in FireFox.

Your DIV is 968px Wide, which for most computers and laptops is absolutely fine.

you must use width:100% or something.If you give id in fixed size then it will create such problem.
Instead of fixed size ,prefer size in percent.

Hello

Reason why it didnt look broken is because of the "overflow:hidden" on 2 main Divs #main-wrap-bottom and #submain-wrap. But overflow:hidden should not be there. I tried clearfix. Didnt work.

you must use width:100% or something.If you give id in fixed size then it will create such problem.
Instead of fixed size ,prefer size in percent.

@IIM, ok I will check each Divs. Thanks

I agree with AHarrisGsy. I don't see any problem with your main-wrap div being 968px. It is within the range of most resolutions people are using today. If you set it to 100% be prepared to start adjusting all the other divs inside of it that were designed with the idea that main-wrap would be a fixed width.

I solved the problem!!! :)
I did process of elimination. Removed and put back some elements.
I found out that the problem was on the search button
the text-indent should be "-9999px" and not "9999px".

Thank you all responders

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.