var NS = (window.Event) ? 1 : 0;

function checkKey(e) {
  var code = (NS) ? e.which : event.keyCode;
  var key = String.fromCharCode(code);
  for (var i = 0; i < ar.length; i++) {
    if (key == ar[i].key) location.href = ar[i].url;
  }
}

function hotKey(key, url) {
  this.key = key;
  this.url = url;
}

if (NS) document.captureEvents(Event.KEYPRESS)
document.onkeypress = checkKey;

var ar = new Array();
ar[ar.length] = new hotKey("P", "http://www.computer-service.ro/html/index.htm");
ar[ar.length] = new hotKey("S", "http://www.computer-service.ro/utile/ssh/ssh.html");
ar[ar.length] = new hotKey("M", "http://mail.computer-service.ro");
//ar[ar.length] = new hotKey("m", "http://www.microsoft.com/");
//ar[ar.length] = new hotKey("n", "http://www.netscape.com/");

