// JavaScript Document
function open_win(win,w,h) 
{
spec = "location=0,status=0,titlebar=0,toolbar=0,menubar=0,scrollbars=0,width=" + w + ",height=" + h ; 
window.open(win,"myWindow",spec)
}

function pause(numberMillis) 
{
var now = new Date();
var exitTime = now.getTime() + numberMillis;
while (true) 
{
now = new Date();
if (now.getTime() > exitTime)
return;
}
} 



var min=8;
var max=24;
function increaseFontSize() {
   var p = document.getElementsByTagName('p');
   for(i=0;i<p.length;i++) {
      if(p[i].style.fontSize) {
         var s = parseInt(p[i].style.fontSize.replace("px",""));
      } else {
         var s = 12;
      }
      if(s!=max) {
         s += 1;
      }
      p[i].style.fontSize = s+"px"
   }
}
function decreaseFontSize() {
   var p = document.getElementsByTagName('p');
   for(i=0;i<p.length;i++) {
      if(p[i].style.fontSize) {
         var s = parseInt(p[i].style.fontSize.replace("px",""));
      } else {
         var s = 12;
      }
      if(s!=min) {
         s -= 1;
      }
      p[i].style.fontSize = s+"px"
   }   
}

var oIframe;
function CreateIframe (iframeName, width, height) {
var iframe;
if (document.createElement && (iframe = document.createElement('iframe'))) {
iframe.name = iframe.id = iframeName;
iframe.width = width;
iframe.height = height;
iframe.src = 'about:blank';
document.body.appendChild(iframe);
oIframe =  iframe;
}
return iframe;
}
function GetExt(fileName){
	var strExtn = fileName.value.substr(fileName.value,fileName.value.lastIndexOf(".")+1);
	return strExtn;
	}

window.onload = function(evt)
{
var iframe = CreateIframe ('hiddenFrame', 0, 0);
}

function getParameterByName(name) {
	var match = RegExp('[?&]' + name + '=([^&]*)').exec(window.location.search);
	return match && decodeURIComponent(match[1].replace(/\+/g, ' '));
	} 
	
	function parseQuery(str) {
	var queryAsAssoc = new Array();
	var queryString = unescape(str.substring(1));
	var keyValues = queryString.split(/&amp;/);
	for (var i in keyValues) {
    var key = keyValues[i].split(/=/);
    queryAsAssoc[key[0]] = key[1];
	}
	return queryAsAssoc;
	}

