function openWindow(lnk, w, h, scrollable) 
	{ 
var width = w || 350
var height = h || 400
var scroll = scrollable || 'no';
open(lnk,"","height="+height+",width="+width+",scrollbars="+scroll+",resizable=no,status=yes,menubar=no,toolbar=no,location=no") 
	} 
// -->	

function popUp(url)
{
	window.open(url, "popup", "width=675,height=540,resizable=yes,status=no,scrollbars=yes");
}

function popUpLamictal(url)
{
	window.open(url, "popup", "width=675,height=540,resizable=yes,status=no,scrollbars=no");
}

if (servername == null){
	var servername="";
}

//increases and decreases the text size by switching style sheets
var typeState = "0";
var ssName = servername + "/epilepsy/css/ep_pat_smstyle.css";
typeCookie = document.cookie;
strBegin = typeCookie.indexOf("largeFonts=");
if (strBegin >= 0){
	typePref = typeCookie.substring((strBegin + 11), (strBegin + 12));
	if (typePref == "1"){
		ssName = servername + "/epilepsy/css/ep_pat_style.css";
		typeState = "1";
   	}	
	else if(typePref == "2"){
		ssName = servername + "/epilepsy/css/ep_pat_lgstyle.css";
		typeState = "2";
	}
}
else{
   document.cookie = "largeFonts=0;path=/";
}
document.write('<link href="'+ssName+'" rel="stylesheet" type="text/css">');
//increases the text size by switching style sheets
function increaseSizeBiggest(){
	ssName = servername + "/epilepsy/css/ep_pat_lgstyle.css";
	typeState = "2";
	document.cookie = "largeFonts="+typeState+";path=/";
	document.location.reload();
}
//increases the text size by switching style sheets
function increaseFontSize(){
	ssName = servername + "/epilepsy/css/ep_pat_style.css";
	typeState = "1";
	document.cookie = "largeFonts="+typeState+";path=/";
	document.location.reload();
}
//decreases the text size by switching style sheets
function decreaseFontSize(){
	ssName = servername + "/epilepsy/css/ep_pat_smstyle.css";
	typeState = "0";
	document.cookie = "largeFonts="+typeState+";path=/";
	document.location.reload();
}

function popup_Eligibility2() {
		open('/epilepsy/patients/resources_and_tools/eligibility_popup.html','','left=20,top=20,width=620,height=770,scrollbars=yes');
    }
