function showMenu(){
	return true;
}

/*window.onresize=resize;
function resize(){
	self.location.href=self.location.href;}*/

if(window.event + "" == "undefined") event = null;
function HM_f_PopUp(){return false};
function HM_f_PopDown(){return false};
popUp = HM_f_PopUp;
popDown = HM_f_PopDown;


/*
META TAGS CONTENT AND DESCRIPTION BELOW
META TAGS CONTENT AND DESCRIPTION BELOW
META TAGS CONTENT AND DESCRIPTION BELOW
*/
document.write('<meta name="keywords" content="Carlsbad National Bank, Bank, carlsbadnational, A financial institution of excellence, featuring secure Internet-based services including Home Banking, Bill Payment, Bill Presentment, Quicken and Money interfaces, Stock Quotes, on-line applications, financial calculators, useful links and a wealth of financial information">');


document.write('<meta name="description" content="ATM, ATM Locations, Account Access, Account Transfer, Automobile Loans, AutoVantage, Bank, Bank Account, Banking, Bill Payment, Bill Presentment, Brokerage, Cash, CDs, Certificates of Deposit, Checks, Checking Accounts, Consumer Loans, Convenience Services, Credit, Credit Card, Credit Card Applications, Credit Union, Digital Insight, Finance, Financial Calculator, Financial Institution, Financial Wizard, Loans, Home Loans, IRA, Money, Term Investment, Online Banking, Order Checks, Personal Financial Management, Rates, Mortgage Rates, Loan Rates, Terms, Retirement, Savings Accounts, Savings, Savings and Loan, Stock Quotes, Stocks, Student Loans, Student, Term Share Certificates, Thrifts, Visa Credit Cards">');
/*
META TAGS CONTENT AND DESCRIPTION ABOVE
META TAGS CONTENT AND DESCRIPTION ABOVE
META TAGS CONTENT AND DESCRIPTION ABOVE
*/


/*
CALL TO CORRECT DIRECTORY
CALL TO CORRECT DIRECTORY
CALL TO CORRECT DIRECTORY
CALL TO CORRECT DIRECTORY
*/


//if you are on homepage you need <script> var homepage = "yes";</script> to make codework properly

var imgdir;
var sitedir;
var securedir;
var homedir;

if(window.homepage)
{
imgdir="images/";
sitedir="site/";
securedir="site/";
homedir="";
}
else if(window.absolutepage)
{
imgdir="http://www.carlsbadnational2.com/images/"
sitedir="http://www.carlsbadnational2.com/site/"
securedir="http://www.carlsbadnational2.com/site/"
homedir="http://www.carlsbadnational2.com/"
}
else if(window.securepage)
{
imgdir="https://www.carlsbadnational2.com/images/"
sitedir="http://www.carlsbadnational2.com/site/"
securedir="https://www.carlsbadnational2.com/site/"
homedir="http://www.carlsbadnational2.com/"
}
else
{
imgdir="../images/";
sitedir="";
securedir="";
homedir="../";
}


// ROLLOVER CODE BELOW ROLLOVER CODE BELOW ROLLOVER CODE BELOW ROLLOVER CODE BELOW
// ROLLOVER CODE BELOW ROLLOVER CODE BELOW ROLLOVER CODE BELOW ROLLOVER CODE BELOW
// ROLLOVER CODE BELOW ROLLOVER CODE BELOW ROLLOVER CODE BELOW ROLLOVER CODE BELOW


browserName = navigator.appName;
browserVer = parseInt(navigator.appVersion);
if (((browserName == "Netscape") && (browserVer >= 3)) || ((browserName =="Microsoft Internet Explorer") && (browserVer >= 4)))
{
version = "ok";
aboutus_on = new Image(71,26);
aboutus_on.src = imgdir + "nav-aboutus-on.gif";

aboutus_off = new Image(71,26);
aboutus_off.src = imgdir + "nav-aboutus-off.gif";

contactus_on = new Image(83,26);
contactus_on.src = imgdir + "nav-contactus-on.gif";

contactus_off = new Image(83,26);
contactus_off.src = imgdir + "nav-contactus-off.gif";

help_on = new Image(49,26);
help_on.src = imgdir + "nav-help-on.gif";

help_off = new Image(49,26);
help_off.src = imgdir + "nav-help-off.gif";

home_on = new Image(88,26);
home_on.src = imgdir + "nav-home-on.gif";

home_off = new Image(88,26);
home_off.src = imgdir + "nav-home-off.gif";

onlinebanking_on = new Image(162,36);
onlinebanking_on.src = imgdir + "nav-onlinebanking-on.gif";

onlinebanking_off = new Image(162,36);
onlinebanking_off.src = imgdir + "nav-onlinebanking-off.gif";

product_on = new Image(184,36);
product_on.src = imgdir + "nav-product-on.gif";

product_off = new Image(184,36);
product_off.src = imgdir + "nav-product-off.gif";

rates_on = new Image(88,36);
rates_on.src = imgdir + "nav-rates-on.gif";

rates_off = new Image(88,36);
rates_off.src = imgdir + "nav-rates-off.gif";

calculators_on = new Image(140,36);
calculators_on.src = imgdir + "nav-calculators-on.gif";

calculators_off = new Image(140,36);
calculators_off.src = imgdir + "nav-calculators-off.gif";


}
else
version = "x";

function img_act(imgName)
{
if (version == "ok")
{
imgOn = eval(imgName + "_on.src");
document [imgName].src = imgOn;
}
}

function img_inact(imgName)
{
oM.mout();
window.status = "";
 if (version == "ok")
{
imgOff = eval(imgName + "_off.src");
document [imgName].src = imgOff;
}
}

// ROLLOVER CODE ABOVE ROLLOVER CODE ABOVE ROLLOVER CODE ABOVE ROLLOVER CODE ABOVE
// ROLLOVER CODE ABOVE ROLLOVER CODE ABOVE ROLLOVER CODE ABOVE ROLLOVER CODE ABOVE
// ROLLOVER CODE ABOVE ROLLOVER CODE ABOVE ROLLOVER CODE ABOVE ROLLOVER CODE ABOVE

//style sheet sniffer
//document.write('<scr'+ 'ipt src="' + securedir + '_styles.js"></scr' + 'ipt>');

function showCalc(calc)
{
var pWidth = ( ((parseInt(screen.width) / 2)) - 275)
var pHeight = (((parseInt(screen.height) / 2)) -240)
window.open(calc,"hello","width=550,height=480,left=" + pWidth + ",top=" + pHeight + ",resizable=1,scrollbars=1");

}
function tabover(howmuch)
{
var farover = '';
farover += '<img src="../images/clearpix.gif" width="' + howmuch + '" height="1" alt="" border="0">';
document.write(farover);
}

function open_apps(nameofapp)
{
var pWidth = ( ((parseInt(screen.width) / 2)) - 350)
var pHeight = (((parseInt(screen.height) / 2)) - 300)
aWindow = window.open('https://www.carlsbadnational2.com/Forms/OnlineForm.cgi?form=' + nameofapp,'application',"toolbar=0,location=0,directories=0,status=0,menubar=0,width=700,height=600,top=" + pHeight + ",left=" + pWidth + ",scrollbars=1,resizable=1,status=1");
}

function third_party(page)
{
var pWidth = ( ((parseInt(screen.width) / 2)) - 250)
var pHeight = (((parseInt(screen.height) / 2)) - 140)
bWindow = window.open(page,'newWin',"toolbar=0,location=0,directories=0,status=0,menubar=0,width=500,height=280,top=" + pHeight + ",left=" + pWidth);
}

function getUrlArgs()
{
	var args = new Object();
	var query = location.search.substring(1);
	//alert("query: " + query);
	var pairs = query.split(",");
	//alert("pairs: " + pairs);
	for(var i = 0; i < pairs.length; i++)
	{
		var pos = pairs[i].indexOf("=");
		if(pos == -1) continue;
		var argname = pairs[i].substring(0, pos);
		//alert("argname; " + argname);
		var value = pairs[i].substring(pos+1);
		var indx = value.indexOf("&");
		
		//if only one parameter is passed (ie- there would be no &)
		if (indx == -1) indx = value.length;
		//alert (indx);
		value = value.substring(0, indx);
		//alert("value: " + value);
		args[argname] = unescape(value);
	}
	//alert("args[argname]: " + args[argname]);
	return args[argname];
}

var myDate = new Date();
var day = myDate.getDay();
var month = myDate.getMonth();
var date = myDate.getDate();
var year = "";

if (document.all)
	{
	year = myDate.getYear();
	}
else
	{
	year =myDate.getYear() + 1900;
	}	

var months = new Array ("January", "February","March", "April", "May", "June", "July", "August", "September", "October", "November", "December");

var days = new Array ("Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday");


//alert (days[day] + ", " + months[month] + " " + date + ",  " + year);
var finalDate = (days[day] + ", " + months[month] + " " + date + ",  " + year);




