redarrow Posted July 28, 2007 Share Posted July 28, 2007 advance thank you. Hello everyone i got a client that is disabled and i need a way but dont no how can not find any solution but need help how can i with a code be able to get a login page come up when you hold down the shift key and a letter, thank for your grate support. any link idear or tutoral would be grate. Quote Link to comment Share on other sites More sharing options...
redarrow Posted July 28, 2007 Author Share Posted July 28, 2007 used java script was easer lol <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <title>onkeypress example</title> <SCRIPT type="text/javascript"> function processKey(event) { if (typeof event == "object" && typeof event.which == "number") { // Netscape style event alert("Netscape: event.which = " + typeof event.which + " " + event.which + " letter is " + String.fromCharCode(event.which)); alert("event.shiftKey = " + event.shiftKey + " event.ctrlKey = " + event.ctrlKey + " event.altKey = " + event.altKey + " event.metaKey = " + event.metaKey); //control-y goes to yahoo if (event.which == 121 && event.ctrlKey == true) { location.replace("http://www.yahoo.com"); return false; } } else { // We assume IE /* *** // Doing an alert seems to confuse IE. // The event will be changed after the alert. alert("IE: window.event.keyCode = " + window.event.keyCode + " letter is " + String.fromCharCode(window.event.keyCode) + "\n" + " window.event.shiftKey = " + window.event.shiftKey + " window.event.ctrlKey = " + window.event.ctrlKey + " window.event.altKey = " + window.event.altKey + "\n" + " ... Warning: " + "IE event handle is confused after this alert"); *** */ //control-y goes to yahoo if (window.event.keyCode == 25 ) { location.replace("http://www.yahoo.com"); window.event.returnValue = false; return; } } return true; } </SCRIPT> </head> <body onkeypress='return processKey(event);'> <p>Lets look for a key press.</p> <form> <input type=text size=20> </form> </body> Quote Link to comment Share on other sites More sharing options...
redarrow Posted July 28, 2007 Author Share Posted July 28, 2007 if you need to hold a key down to got to a page for example the code will goto yahoo while holding down CTL + letter y save the page as a .php and include("the_page_name.php"); all the bes redarrow Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.