function OpenCertDetails()
	{
	thewindow = window.open('https://www.GoDaddy.com/cgi/server/certdetails.exe?code=USHUBC2-2', 'anew', config='height=512,width=513,toolbar=no,menubar=no,scrollbars=yes,resizable=no,location=no,directories=no,status=yes');
}


//Totaling Code

//ecosalescheck
//cssalescheck

function figuretotal(whichstate, useexp, whichexp, overchecked, ecocheck, corpcheck) {
	var total;
	var servicefee = 99.95;
	var SH = 7;

	total = SH + servicefee;
	total += eval(document.orderform.state.options[whichstate].value);
	if (useexp) {
		total += eval(document.orderform.expstate.options[document.orderform.expstate.selectedIndex].value);
	}
	if (overchecked) {
		total += 44;
	}
	if (ecocheck) {
		total += 66.95;
	}
	/*if (ecosalescheck) {
		total += 6.29;
	}*/
	if (corpcheck) {
		total += 29.99;
	}
	/*if (cssalescheck) {
		total += 3.14;
	}*/
	total = Math.round(total*100)/100

	return total;
}

function openWindowECO() 
	{     popupWin=window.open('execcorpoutfit.html','remotepriv','scrollbars=yes,width=460,height=450,top=100,left=100')
}

function openWindowCorpSeal() 
    {
popupWin=window.open('corporateseal.html','remotefriend','scrollbars=yes,width=440,height=450,top=33,left=33')
}

function CheckData(info) { document.orderform.check_amount.value = document.orderform.totalcharge.value 
}



function popWin(url,width,height,posx,posy) {
var myWindow = window.open(url, "mainWin", 'resizable=0,toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,width='+width+',height='+height+',screenX='+posx+',screenY='+posy+',left='+posx+',top='+posy+'');
myWindow.focus()
}


//Validation

var goahead;

function validate() {
	for(var i=0;i < document.forms[0].elements.length;i++){
		var ele=document.forms[0].elements[i];
		if(ele.name=="your_name" && ele.value==""){alert('Please enter your name.');ele.focus();goahead == "no"; return goahead;}
		if(ele.name=="your_address" && ele.value==""){alert('Please enter your address.');ele.focus();goahead == "no"; return goahead;}
		if(ele.name=="your_city" && ele.value==""){alert('Please enter your city.');ele.focus();goahead == "no"; return goahead;}
		if(ele.name=="your_state" && ele.value==""){alert('Please enter your state.');ele.focus();goahead == "no"; return goahead;}
		if(ele.name=="your_zip" && ele.value==""){alert('Please enter your zip code.');ele.focus();goahead == "no"; return goahead;}
		if(ele.name=="Your_day_phone" && ele.value==""){alert('Please enter your day phone number.');ele.focus();goahead == "no"; return goahead;}
		if(ele.name=="Your_fax" && ele.value==""){alert('Please enter your fax number.');ele.focus();goahead == "no"; return goahead;}
		if(ele.name=="email_address" && ele.value==""){alert('Please enter your email address.');ele.focus(); goahead == "no"; return goahead;}
		if(ele.name=="inc_name_1" && ele.value==""){alert('Please enter a first choice for your company name.');ele.focus(); goahead == "no"; return goahead;}
		if(ele.name=="inc_address" && ele.value==""){alert('Please enter the address for your company.');ele.focus(); goahead == "no"; return goahead;}
		if(ele.name=="inc_city" && ele.value==""){alert('Please enter the city in which your company is located.');ele.focus(); goahead == "no"; return goahead;}
		if(ele.name=="inc_state" && ele.value==""){alert('Please enter the state in which your company is located.');ele.focus(); goahead == "no"; return goahead;}
		if(ele.name=="inc_zip" && ele.value==""){alert('Please enter the zip code in which your company is located.');ele.focus(); goahead == "no"; return goahead;}
	}
	goahead = "yes";
}


function validate1() {
	for(var i=0;i < document.forms[0].elements.length;i++){
		var ele=document.forms[0].elements[i];
		if(ele.name=="your_name" && ele.value==""){alert('Please enter your name');ele.focus();goahead == "no"; return goahead;}
		if(ele.name=="your_address" && ele.value==""){alert('Please enter your address');ele.focus();goahead == "no"; return goahead;}
		if(ele.name=="your_city" && ele.value==""){alert('Please enter your city');ele.focus();goahead == "no"; return goahead;}
		if(ele.name=="your_state" && ele.value==""){alert('Please enter your state');ele.focus();goahead == "no"; return goahead;}
		if(ele.name=="your_zip" && ele.value==""){alert('Please enter your zip code');ele.focus();goahead == "no"; return goahead;}
		if(ele.name=="Your_day_phone" && ele.value==""){alert('Please enter your day phone number');ele.focus();goahead == "no"; return goahead;}
		/*if(ele.name=="Your alternate phone" && ele.value==""){alert('Please enter an alternate phone number');ele.focus();goahead == "no"; return goahead;}*/
		if(ele.name=="Your_fax" && ele.value==""){alert('Please enter your fax number');ele.focus();goahead == "no"; return goahead;}
		if(ele.name=="email_address" && ele.value==""){alert('Please enter your email address');ele.focus(); goahead == "no"; return goahead;}
		if(ele.name=="inc_name_1" && ele.value==""){alert('Please enter a first choice for your company name');ele.focus(); goahead == "no"; return goahead;}
		if(ele.name=="registered_agent_name" && ele.value==""){alert('Please enter the name of your Registered Agent');ele.focus(); goahead == "no"; return goahead;}
		if(ele.name=="agent_address" && ele.value==""){alert('Please enter the address of your Registered Agent');ele.focus(); goahead == "no"; return goahead;}
		if(ele.name=="agent_city" && ele.value==""){alert('Please enter the city of your Registered Agent');ele.focus(); goahead == "no"; return goahead;}
		if(ele.name=="agent_state" && ele.value==""){alert('Please enter the state of your Registered Agent');ele.focus(); goahead == "no"; return goahead;}
		if(ele.name=="agent_zip" && ele.value==""){alert('Please enter the zip of your Registered Agent');ele.focus(); goahead == "no"; return goahead;}
	}
	goahead = "yes";
}

function doit() {
	validate();
	if (goahead == "yes") {
		document.orderform.submit();
	}
	/*else {
		alert("oh damn.");
	}*/
}

function doit1() {
	validate1();
	if (goahead == "yes") {
		document.orderform.submit();
	}
}


//Date
var d_obj=new Date();
var d_day=d_obj.getDay();var d_month=d_obj.getMonth();var d_date=d_obj.getDate();var d_year=d_obj.getYear();
var dday=new Array();
dday[0]="Sunday";dday[1]="Monday";dday[2]="Tuesday";dday[3]="Wednesday";
dday[4]="Thursday";dday[5]="Friday";dday[6]="Saturday";
var dmonth=new Array();dmonth[0]="Jan.";dmonth[1]="Feb.";dmonth[2]="Mar.";dmonth[3]="Apr.";
dmonth[4]="May";dmonth[5]="Jun.";dmonth[6]="Jul.";dmonth[7]="Aug.";dmonth[8]="Sep.";
dmonth[9]="Oct.";dmonth[10]="Nov.";dmonth[11]="Dec.";
if(d_year<200){d_year+1900};
var date_full = dday[d_day] + ', ' + dmonth[d_month] + ' ' + d_date + ', ' + d_year;


// Bookmark
function team_bookmark(){/*Copyright www.team-orange.net*/var u='http://www.team-orange.net';var w=window;var l=(u=='http://www.team-orange.net')?w.location:u;var e=w.external;(l!=''||e==null)?e.AddFavorite(l):e=null;}


//rollovers
bname = navigator.appName;
bversion = parseFloat(navigator.appVersion);

var base_dir = "images/";
var imgs = new Array('butt-inc-over.gif','butt-llc-over.gif','butt-nonprofit-over.gif','butt_cert_authority-over.gif','butt-kits-over.gif','butt-agent1-over.gif','butt-notary-over.gif','butt-corp-over.gif','butt-printing-over.gif','butt-custom-over.gif','butt-irs-over.gif','butt-contact-over.gif','click-over.jpg','butt-ps-over.gif');
       for (var i=0; i < imgs.length; i++) {
       var img = new Image();
       img.src = base_dir + imgs[i];
       }
function rollover(name1,img1){
	if (bname == "Netscape") {
		if (bversion < 5) {
			return false;
			}
		}
	if (bname == "Netscape") {
		if (bversion >= 5) {
			document.images[name1].src = base_dir + img1;
			}
		}
		else{
             document.images[name1].src = base_dir + img1;
             }
	}