I have a login matrix script that I've written in JavaScript, where I use console.inkey() to get a keypress from the user with an input timeout. I'm using a timeout of 60000ms (so, it should time out after 60 seconds). It wo fine with a fast internet connection, but I've noticed that if I log into my BBS from a computer with a fairly slow connection (i.e., satellite internet connection with a fairly slow upload rate), it times out immediately. Is the a workaround for this?
I have a login matrix script that I've written in JavaScript, where I use console.inkey() to get a keypress from the user with an input timeout. I'm using a timeout of 60000ms (so, it should time out after 60 seconds). It works fine with a fast internet connection, but I've noticed that if I log into my BBS from a computer with a fairly slow connection (i.e., satellite internet connection with a fairly slow upload rate), it times out immediately. Is there a workaround for this?
Here's what I use. Keep in mind this is ripped from ispy/tracker1's code
of the phoenix modded s3 shell script.
var c = console.inkey();
if (c == "") {
sleep(100);
}else{
Determine key pressed, etc etc etc.
What is the return value? Is it possible that there were simply keys sti pending on the socket?
Please report bugs instead of working around them. :-)
Sysop: | Chris Crash |
---|---|
Location: | Huntington Beach, CA. |
Users: | 578 |
Nodes: | 8 (0 / 8) |
Uptime: | 29:15:22 |
Calls: | 10,736 |
Calls today: | 1 |
Files: | 5 |
Messages: | 443,196 |
Posted today: | 1 |