var tm = 30;
function $(a) {
  return document.getElementById(a);
}
function ShowTimer() {
  $("timer").innerHTML = tm--;
  if (tm>0)
    setTimeout("ShowTimer()",1000);
  else 
    document.location.href = $("link").href;
}
function parseArgs() {
  var a, res = {};
  var objs = document.location.href.split(/\?|&/);
  for (i=0; i<objs.length; i++) {
    a = objs[i].split("=");
    if (a[1]) res[a[0]] = unescape(a[1]);
  }
  return res;
}
