CSS - 1 Page in Site Shifts From Center

He has: 578 posts

Joined: Jun 2004

Hey. I'm just finishing up the first draft of a site for a local dance studio, and i'm afraid this will be tough to see with in IE, because I haven't gone in and edited the code yet so it looks remotely viewable.

Anyway, if you go to http://davidbacsik.awardspace.com , and click on "history" and compare it to any of the other pages, it's shifted slightly right. I have no idea why this is happening, and I assume I'm missing something stupid in the code, but I can't figure it out. A little help? I thought at first that it may be something in the page specific css files, but index has no special css, and it is normal too.

CSS: http://davidbacsik.awardspace.com/includes/main.css
http://davidbacsik.awardspace.com/includes/classes.css
http://davidbacsik.awardspace.com/includes/teachers.css

Megan's picture

She has: 11,421 posts

Joined: Jun 1999

It looks fine to me in IE6. In Opera and Firefox it shifts because the scrollbar does not appear on pages that aren't long enough to scroll. So when the scrollbar appears it shifts. This always happens when pages are too short for a scrollbar.

There might be a way to force a scrollbar using javascript. Or, since this is only happening in browsers that support it, you could put a min-height on the content div or something to make sure the page is always long enough to scroll.

They have: 2 posts

Joined: Nov 2006

Wow, I had a similar problem, and this fixed it. Thanks Megan!

-mc

He has: 578 posts

Joined: Jun 2004

Thanks! Knew I was missing something.

Next issue....
in IE 5 on a mac (don't know about the rest), the width of the ul that makes up the links to the teacers needs to be wider. I can style it fine inline (style="width: 200px;"), but as soon as i turn it into a class, it does absolutely nothing. I checked spelling, etc...

Has anyone heard of anything like this?

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.