Solved

Web pages move if windows has to add a scroll bar on long pages.  Workaround ?

Posted on 2011-09-12
3
262 Views
Last Modified: 2012-05-12
I am working on a website for a friend, and I have basic knowledge of css & html.  I want all of the pages to be anchored in the exact same spot (left to right, and distance from the top).  They are all based on the same Dreamweaver template.  The problem that I have (which I admit is pretty nitpicky) is that when any of the pages are too long to fit vertically on the screen, Windows adds scrollbars on the right side of the screen display so that the user can scroll down to see the entire webpage.  That shifts the longer pages to left by a width 1/2 of the scrollbars because my left and right margins are set to auto, and the Windows scrollbars decrease the available screen width.

I like having the padding set to auto so that it is easy to center the page for any screen resolution, but maybe there is a way to get the screen resolution, then calculate what a fixed left margin would be so that the pages would appear to be always in the middle and not move even if the scrollbars appeared on the long pages and reduced the screen width by a bit....  Or maybe there is another way.

Is there something cool and easy that I could do to get around this, or is it more trouble than it is worth ?

Thanks !
0
Comment
Question by:Kevin
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 30

Accepted Solution

by:
LZ1 earned 500 total points
ID: 36522714
Have you taken a look at this?
http://haslayout.net/css-tuts/Fixing-Page-Shift-Problem

IMHO I think it's more trouble than it's worth. IE is an inferior browser with more quirks than people know what to do with.  You may find that you NEED to fix this, so the fix above should be all you need.
0
 

Author Closing Comment

by:Kevin
ID: 36522987
Perfect.  Now I just need to decided as you suggest whether it is worth the trouble.  Thanks!
0
 
LVL 30

Expert Comment

by:LZ1
ID: 36523037
That's the hardest part now. ;)  Good luck!
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
When crafting your “Why Us” page, there are a plethora of pitfalls to avoid. Follow these five tips, and you’ll be well on your way to creating an effective page.
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question