FRIHOST FORUMS SEARCH FAQ TOS BLOGS COMPETITIONS
You are invited to Log in or Register a free Frihost Account!


Scroll bottom of web page all the way to the top?





Peterssidan
Is it possible to make so that Firefox can scroll the bottom of the page all the way to the top? Does any browser have this feature?

Geany, which is an IDE, can do this. I sometimes find it useful when having another window open in front and I can still scroll to see everything in the whole document without defocus or move the other window.
likeabreeze
Peterssidan wrote:
Is it possible to make so that Firefox can scroll the bottom of the page all the way to the top? Does any browser have this feature?

Geany, which is an IDE, can do this. I sometimes find it useful when having another window open in front and I can still scroll to see everything in the whole document without defocus or move the other window.


By Geany, you mean the text editor?
Can you explain that in detail?
Peterssidan
Yes I mean Geany the text editor. The feature I talk about can be toggled at File > Preferences > Editor > Display > Stop scrolling at last line.
ocalhoun
If you just want to scroll to the top instantly, the <home> button on your keyboard is what you're looking for.

Other than that, there are several autoscrolling addons for firefox. Just go get one of those.
Ankhanu
You can assign a gesture to do it in OS X. I have mine set so that a vertical 3-finger swipe takes me to the top or bottom of a page.

CMD+up or CMD+dn will also do it.
jmraker
In firefox pressing the HOME key (or Control+HOME) will scroll to the top of the page.
Pressing the END key (or Control+END) will scroll to the bottom of the page

If you want to insert links that do that you can use anchor names and put a <a id="top" name="top"></a> at the top of the document, and a <a id="bottom" name="bottom"></a> at the bottom of the document and use the links <a href="#bottom">Scroll to bottom</a>

You can also do this in JavaScript by setting the scroll offset.
Peterssidan
Thank you, I appreciated all the answers. I know how to scroll to the top and bottom of a page. I often use HOME and END, but what I was trying to ask about was if it was possible to make the scroll go further down so that the last line, which is
Quote:
2005-2011 Frihost, forums powered by phpBB.
on this page, can be scrolled all the way to the top. I don't know what it would show under the last line but that's not important.
jmraker
To do that in firefox on every page would require something like a greasemonkey script to add enough padding-bottom/margin-bottom to the <body> element when the END key is pressed or on page load so it can scroll an additional amount than intended.
http://en.wikipedia.org/wiki/Greasemonkey

A quick search of the public scripts didn't find anything that looked useful.
http://userscripts.org/
ocalhoun
Peterssidan wrote:
Thank you, I appreciated all the answers. I know how to scroll to the top and bottom of a page. I often use HOME and END, but what I was trying to ask about was if it was possible to make the scroll go further down so that the last line, which is
Quote:
2005-2011 Frihost, forums powered by phpBB.
on this page, can be scrolled all the way to the top. I don't know what it would show under the last line but that's not important.

Use the greasemonkey addon for firefox, then you can add a greasemonkey script for this website that adds in blank space below that point.
That would do it.
Nyasro
wordpress???
Peterssidan
Ok so I wrote a greasmonkey script to do it. I prefer if always some content is visible so I have the alwaysVisible variable that is currently set to 50, meaning 50 pixels of the page should still be visible when scrolled all the way down. I don't want the END button to scroll me past the end of the page so I had to override the default action.
Code:
// ==UserScript==
// @name           Scroll bottom of page to the top
// @include        http*
// ==/UserScript==

var alwaysVisible = 50;
var elem = document.createElement("div");

function adjustHeight()
{
   elem.style.height = (window.innerHeight - alwaysVisible) + "px";
}

function keyDown(event)
{
   if (event.keyCode == 35 && !event.shiftKey)
   {
      var ae = document.activeElement;
      if (ae)
      {
         var tagName = ae.tagName.toLowerCase();
         if (tagName == "textarea" || tagName == "input" && ae.type == "text")
         {
            return;
         }
      }
      event.preventDefault();
      window.scrollTo(window.pageXOffset, elem.offsetTop - window.innerHeight);
   }
}

elem.style.clear = "both";
elem.style.cssFloat = "left";
elem.style.margin = "0px";
elem.style.padding = "0px";
adjustHeight();
document.body.appendChild(elem);

window.addEventListener("resize", adjustHeight, false);
window.addEventListener("keydown", keyDown, false);
Related topics
Beautiful personal web page!
Which is the best content management software
How Do You Center Your Entire Web Page?
LOST
web page maker
web page maker
Web Page Maker
Department web page
how long does web page posts take ???
Anyone know how to make an email form?
Help on making a web page
secure your pictures on a web page !
how to insert data into mysql base from a web page
Looking for a place to start a business Web page
Simple code to make your web page !
Reply to topic    Frihost Forum Index -> Computers -> Software

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2011 Frihost, forums powered by phpBB.