Computer Chess Club Archives


Search

Terms

Messages

Subject: Shortcut for next CCC message numerically

Author: Roy Eassa

Date: 07:54:50 11/20/02


OK, this is my first time trying to program in JavaScript.  Selecting this
shortcut in IE6 (Windows) takes me to the next CCC message, numerically.  I
think I can assign a key to this so a single keystroke will take me to the next
message, instead of always going back to the index.

It will probably only work in Windows, and maybe only in IE.  Perhaps somebody
else could generalize it for all browsers (assuming JavaScript support, of
course)?

Put the following 2 lines into a text file and save it in your shortcuts:

[InternetShortcut]
URL=javascript:{var n=0;var
q=0;q=location.href.lastIndexOf('?');n=parseInt(location.href.substring(q+1,location.href.length))+1;location.href=location.href.substring(0,q+1)+n;}


(Note that it's two lines long.  The second line is quite long and will be shown
here as wrapping. As I understand it, it only works if the actual JavaScript is
all on one line.)



This page took 0.01 seconds to execute

Last modified: Thu, 15 Apr 21 08:11:13 -0700

Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.