peterozumurray
Power User
Posts: 9
|
 |
« Reply #1 on: October 26, 2007, 11:28:54 PM » |
|
This is not necessarily that elegant of a solution (and others may suggest better ones), but it's one which I put together using simple, existing resources and which works for me not only on Google but many other sites that use an link called "next" or "next page" to send users to the next page. The following works for Firefox (FF); I have no idea if it would work on IE.
(1) create a new bookmark in FF, e.g., by right-clicking on your bookmarks toolbar and selecting 'new bookmark'. Title it something like 'next page' (or whatever; the title is non-essential);
(2) Paste the following javascript into the location box (it searches the current page for links tagged "next" or "next page" and selects them if it does, and returns a dialog with "Can't find link to next page" if it doesn't):
javascript:(function(){function linkIsSafe(h){return(!/^mailto:/.exec(h)&&!/^javascript:/.exec(h));} var i,x,h; for(i=0;x=document.getElementsByTagName('a');i++) { h=x.innerHTML.toLowerCase(); if(h.indexOf('next page')>-1 || h.indexOf('next')>-1 && linkIsSafe(x.href)) { x.focus();location=x.href;return; }} alert(%22Can't find link to next page.%22);})()
(3) IMPORTANT: type "next" for the bookmark keyword. Click OK to close your new bookmark. You can save this bookmark whereever you want.
(4) open the Keybreeze macro editor. Paste the following into the macro space:
<ctrl d>l<ctrl u>next<delay 250><enter>
(5) IMPORTANT: save the macro you've just created as "n next page in FF". Follow the rest of the instructions in Keybreeze for setting up a keyword to trigger the macro (essentially, add a keyword called "n next page in FF", and set the target to "macro"). You're naming it like this both so that it is usefully descriptive and, more importantly, so that it comes up first when you start to type your keyword, which allows you to exploit the Keybreeze autofill feature to minimize your keystrokes.
Now, when you are in FF, at a Google search page, for instance, you just trigger Keybreeze with your hotkey, type "n", Keybreeze will autofill to "n next page in FF", and you press enter. Three keystrokes from you; Keybreeze (and the bookmark you've created) does the rest (which is to press ctrl+L, sending focus to the address bar, then enter "next", which triggers the javascript you bookmarked, which then searches the page for the "next" or "next page" link).
|