Hexagora Forum
Hexagora Forum
Home | Profile | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Dynamic HTML Editor
 Dynamic HTML Editor
 Page shift
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

jtarin
Super User

Russia
444 Posts

Posted - 22 Aug 2010 :  13:05:02  Show Profile  Visit jtarin's Homepage  Reply with Quote
Got a problem not seemingly solved as I've not run against it before when it hasn't been fixable.
When making a page transition (link) from my index page to any page that I have a (major size)text box constructed in, the page seems to shift to the left about 10px and upon going back it is the reverse...of course. I have checked positioning of all duplicate elements and they coincide. The only difference between the two would be text box size and font, but I have removed the large text box entirely and there is still a shift. Probably something obvious. Pages are centered and background is no scroll repeat.

Porky
www.pacificwavetour.com

Edited by - jtarin on 22 Aug 2010 13:08:52

2hats
Practical

36 Posts

Posted - 22 Aug 2010 :  23:03:01  Show Profile  Visit 2hats's Homepage  Reply with Quote
Check for browser vertical scrollbar on right of screen for page that shifts left.
Go to Top of Page

jtarin
Super User

Russia
444 Posts

Posted - 22 Aug 2010 :  23:39:14  Show Profile  Visit jtarin's Homepage  Reply with Quote
That's what I didn't remember....thanks. Had that problem many moons ago and forgot the solution.

Porky
www.pacificwavetour.com
Go to Top of Page

s.dav
Site Admin

Italy
3364 Posts

Posted - 23 Aug 2010 :  09:05:55  Show Profile  Visit s.dav's Homepage  Reply with Quote
The next version will have an option to fix this problem ;-)
The tip is to make the scrollbar always visible.

Regards, Davide
Go to Top of Page

jtarin
Super User

Russia
444 Posts

Posted - 24 Aug 2010 :  04:41:51  Show Profile  Visit jtarin's Homepage  Reply with Quote
Thanks Davide...I remember using that fix on an old site I made with version 2, I believe. There was another solution where with a script I seem to remember, but I've lost that somewhere along the way. :)

Porky
www.pacificwavetour.com
Go to Top of Page

jtarin
Super User

Russia
444 Posts

Posted - 25 Aug 2010 :  00:51:16  Show Profile  Visit jtarin's Homepage  Reply with Quote
OK....I have it set up like I want but one thing I would like to change. The scrollbar is to the exact edge of the textbox and up against the endline of text. I would like to have a space there. Is there an easier way to do it than editing each line and placing "." as a spacer and using background color?

Porky
www.pacificwavetour.com
Go to Top of Page

s.dav
Site Admin

Italy
3364 Posts

Posted - 25 Aug 2010 :  08:53:10  Show Profile  Visit s.dav's Homepage  Reply with Quote
Actually no, sorry
What method did you use?

Regards, Davide
Go to Top of Page

2hats
Practical

36 Posts

Posted - 26 Aug 2010 :  00:04:03  Show Profile  Visit 2hats's Homepage  Reply with Quote
I find a good solution is to start with a 'layer' 960 wide by 960 high, and place all other components inside that.
Adjust the layer height to ensure scrollbar displays to right.
Use that 'layer' and size as template for all website pages.
Go to Top of Page

s.dav
Site Admin

Italy
3364 Posts

Posted - 26 Aug 2010 :  15:16:55  Show Profile  Visit s.dav's Homepage  Reply with Quote
Try to add this piece of code to your page header:

<style type="text/css">
body {overflow-y: scroll;}
</style>


Regards, Davide
Go to Top of Page

Martin1
Super User

Netherlands
626 Posts

Posted - 30 Aug 2010 :  16:06:36  Show Profile  Reply with Quote
I always use this in my pages:
html {
overflow-y: scroll;
}
this works across all browsers and doesn't create a problem when a scroll bar is needed (with a very long page).

I have tried several methods and most created some sort of problem. This rather simple one doesn't.
Go to Top of Page

s.dav
Site Admin

Italy
3364 Posts

Posted - 31 Aug 2010 :  08:51:21  Show Profile  Visit s.dav's Homepage  Reply with Quote
Martin, I checked also mine and seems to work with All Windows browsers...
I haven't checked it on Mac or Linux; in the next days I'll try ;-)

Thank you for the tip ;-)

Regards, Davide
Go to Top of Page

Martin1
Super User

Netherlands
626 Posts

Posted - 31 Aug 2010 :  16:56:44  Show Profile  Reply with Quote
Hello Davide,

I did try yours as well and couldn't find any problem with it.

However I do remember that in the past I did have problems with it. Maybe it was due to an older browser version or something I can't remember but there was a reason I started using my version.

Martin
Go to Top of Page

Martin1
Super User

Netherlands
626 Posts

Posted - 03 Sep 2010 :  01:27:23  Show Profile  Reply with Quote

The HTML5 boilerplate that was created by Paul Irish, and Divya Manian shows on line 157 http://html5boilerplate.com/ the html version and not the body version.

html { overflow-y: scroll; }
Go to Top of Page

s.dav
Site Admin

Italy
3364 Posts

Posted - 03 Sep 2010 :  10:14:35  Show Profile  Visit s.dav's Homepage  Reply with Quote
Good, I'll modify it ;-)

Regards, Davide
Go to Top of Page

Martin1
Super User

Netherlands
626 Posts

Posted - 06 Oct 2010 :  15:46:46  Show Profile  Reply with Quote
Hello Davide,

I just noticed that you still went with

<style type="text/css">
body {overflow-y: scroll;}
</style>

instead of

<style type="text/css">
html { overflow-y: scroll; }
</style>

Why?
Go to Top of Page

s.dav
Site Admin

Italy
3364 Posts

Posted - 07 Oct 2010 :  13:52:56  Show Profile  Visit s.dav's Homepage  Reply with Quote
Because your method is causing problems with some scripts (opening a DIV containing an IFRAME with a overflow-y:scroll on the HTML causes some browser to display the DIV in a wrong way (without the scroll)) so I returned back to my method.
If you'll find a reason to return back to your method please let me know.

Regards, Davide
Go to Top of Page

Martin1
Super User

Netherlands
626 Posts

Posted - 07 Oct 2010 :  17:06:40  Show Profile  Reply with Quote
Thanks for the heads up Davide!

I didn't know that such an issue could arise.
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
Hexagora Forum © s.dav Go To Top Of Page
Snitz Forums 2000