getting horizontal scroll when i set to 100%

They have: 426 posts

Joined: Feb 2005

I have set my header to 100% width and for some reason it is giving me a horizontal scroll bar? I have tested this be setting everything else on the page to smaller % and then the header to a smaller % and this seems to be the problem.

You can view it here: http://www.phpstarter.net/theglobalarts/cpg1414/index.php

Please advise, this is very frustrating.

Renegade's picture

He has: 3,022 posts

Joined: Oct 2002

From what I can see, it looks like in #sys_menu you have a left:10px; which is pushing it right by 10px as it's supposed to do. If you remove that and instead used something like padding, it should remove your horizontal scrollbar Smiling

They have: 426 posts

Joined: Feb 2005

thanks for that. How the hell did you know it was that?

JeevesBond's picture

He has: 3,956 posts

Joined: Jun 2002

I would guess that he's using Firebug, it's really handy for debugging CSS problems. Let's just hope it doesn't make Webmaster forums redundant! Smiling

Renegade's picture

He has: 3,022 posts

Joined: Oct 2002

I should have used firebug but I didn't. Just followed the process I take when debugging my own code.

1, Look at the source code, are there tables or divs?
2, turn on borders for tables, anything wrong?
3, turn on borders for divs, anything wrong?

When I saw the borders for your divs up the top, I saw that it was moved to the right and therefore creating your horizontal scroll.

Next step was to look at your css for the top divs Smiling

Hope this helps in your future debugging Smiling

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.