function popwin(winurl, w, h)  {
	parms = 'toolbar=1,scrollbars=yes,location=0,statusbar=1,status=yes,print=no,menubar=yes,resizable=1,width='+ w + ',height=' + h + ',left=10,top=10';
	newwin = window.open(winurl,'uslf',parms);
}
function GoThere(f) {
	top.location.href = f.chooser.options[f.chooser.selectedIndex].value;
}
function helpwindow(URL) {
	day = new Date();
	id = day.getTime();
	eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=1,scrollbars=yes,location=0,statusbar=1,status=yes,print=no,menubar=yes,resizable=1,width=700,height=450,left = 20,top = 50');");
}
function helpwindow2(URL) {
	day = new Date();
	id = day.getTime();
	eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=1,scrollbars=yes,location=1,statusbar=1,status=yes,print=no,menubar=yes,resizable=1,width=700,height=450,left = 20,top = 50');");
}
function helpwindow3(URL) {
	day = new Date();
	id = day.getTime();
	eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=no,location=0,statusbar=0,status=no,print=no,menubar=no,resizable=0,width=550,height=400,left = 20,top = 50');");
}
function helpwindow5(URL) {
	day = new Date();
	id = day.getTime();
	eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=yes,location=0,statusbar=0,status=no,print=no,menubar=no,resizable=0,width=550,height=400,left = 20,top = 50');");
}
var US_acceptsCookies = false;
if(document.cookie == '') {
    document.cookie = 'US_acceptsCookies=yes';
    if(document.cookie.indexOf('US_acceptsCookies=yes') != -1) {
	US_acceptsCookies = true; 
    }
} else {
  US_acceptsCookies = true;
}
function US_setCookie (name, value, hours, path, domain, secure) {
    if (US_acceptsCookies) {
	var not_NN2 = (navigator && navigator.appName 
		       && (navigator.appName == 'Netscape') 
		       && navigator.appVersion 
		       && (parseInt(navigator.appVersion) == 2))?false:true;

	if(hours && not_NN2) {
	    if ( (typeof(hours) == 'string') && Date.parse(hours) ) {
		var numHours = hours;
	    } else if (typeof(hours) == 'number') { // calculate Date from number of hours
		var numHours = (new Date((new Date()).getTime() + hours*3600000)).toGMTString();
	    }
	}
	document.cookie = name + '=' + escape(value) + ((numHours)?(';expires=' + numHours):'') + ((domain)?';domain=' + domain:'') + ((path)?';path=' + path:'') + ((secure && (secure == true))?'; secure':''); // Set the cookie, adding any parameters that were specified.
    }
} // US_setCookie
function US_readCookie(name) {
    if(document.cookie == '') {
	return false; 
    } else {
	var firstChar, lastChar;
	var theBigCookie = document.cookie;
	firstChar = theBigCookie.indexOf(name);
	var NN2Hack = firstChar + name.length;
	if((firstChar != -1) && (theBigCookie.charAt(NN2Hack) == '=')) {
	    firstChar += name.length + 1;
	    lastChar = theBigCookie.indexOf(';', firstChar);
	    if(lastChar == -1) lastChar = theBigCookie.length;
	    return unescape(theBigCookie.substring(firstChar, lastChar));
	} else { 
	    return false;
	}
    }	
}
function US_killCookie(name, domain, path) {
  var theValue = US_readCookie(name);
  if(theValue) {
      document.cookie = name + '=' + theValue + '; expires=Fri, 13-Apr-1970 00:00:00 GMT' + ((domain)?';domain=' + domain:'') + ((path)?';path=' + path:'') ; // set an already-expired cookie
  }
}
var qsParm = new Array();
function qs() {
	var query = window.location.search.substring(1);
	var parms = query.split('&');
	for (var i=0; i<parms.length; i++) {
   		var pos = parms[i].indexOf('=');
   			if (pos > 0) {
     		 var key = parms[i].substring(0,pos);
     		 var val = parms[i].substring(pos+1);
      		qsParm[key] = val;
     	 }
  	 }
}
qsParm['auslf'] = null;
qsParm['puslf'] = null;
qs();
var partner_value = qsParm['auslf'];
var ppc_value = qsParm['puslf'];
if(ppc_value !== null)
{	
	if (US_readCookie('Affiliate')) {	
	US_killCookie('Affiliate', 'uslegalforms.com', '/');
	}
	var cookieValue = ppc_value;
  	var cookiename = "PPC="+ppc_value;		
	var exdate=new Date()
	exdate.setDate(exdate.getDate()+1)
	var expires= ";expires="+exdate;
	var domain = ";domain=uslegalforms.com";
	var path = ";path=/";
    var theCookie = cookiename + expires + domain + path;
    document.cookie =  theCookie;	
}
if(partner_value !== null)
{
	if (US_readCookie('Affiliate')) {
	US_killCookie('Affiliate', 'uslegalforms.com', '/');
	}
	var cookieValue = partner_value;
  	var cookiename = "Affiliate="+partner_value;		
	var exdate=new Date()
	exdate.setDate(exdate.getDate()+90)
	var expires= ";expires="+exdate;
	var domain = ";domain=uslegalforms.com";
	var path = ";path=/";
    var theCookie = cookiename + expires + domain + path;
    document.cookie =  theCookie;
}