<!-- // Hide from old browsers
function openWin(url,name,width,height) {
	var tpwin=window.open(url,name,'width='+width+',height='+height+',center,menubar=no,scrollable=yes,scrollbars=yes,resizable=yes');
}

function swapImage(img,src) {
	window.document.images[img].src = src;
}

function openWin1() {
var n=window.open('/contact.html','wincontact','width=350,height=250,center,menubar=no,scrollable=no,resizable=yes');
}

function openWinDiscount() {
var dw=window.open('/discount.html','windiscount','width=350,height=300,center,menubar=no,scrollable=no,resizable=yes');
}

function openWinFlash(file,name,width,height) {
var winwidth = width + 30;
var winheight = height + 30;
var parms = "width=" + winwidth + ",height=" + winheight + ",center,menubar=no,location=no,status=no,scrollable=no,resizable=yes";
var url = file + "&width=" + width + "&height=" + height
var flashwin = window.open(url, name, parms);
}

function openWinShipping() {
	var urlquery = '/shippingpopup.html';
	var tpwin=window.open(urlquery,'winshipping','width=600,height=700,center,menubar=no,scrollable=yes,scrollbars=yes,resizable=yes');
}

function openWinBGSpecial() {
	var urlquery = '/includes/BGspecialpopup.html';
	var tpwin=window.open(urlquery,'winBGspecial','width=800,height=600,center,menubar=no,scrollable=yes,scrollbars=yes,resizable=yes');
}

function openWinVideoSpecial() {
	var urlquery = '/includes/VideoSpecialpopup.html';
	var tpwin=window.open(urlquery,'winvidspecial','width=800,height=600,center,menubar=no,scrollable=yes,scrollbars=yes,resizable=yes');
}

function openWinIntCC() {
	var urlquery = '/policy.html#InternationalShipping';
	var tpwin=window.open(urlquery,'winintcc','width=700,height=300,center,menubar=no,scrollable=yes,scrollbars=yes,resizable=yes');
}

function openWinTestPass(data) {
	var urlquery = '/testpasspopup.html?avail=' + data;
	var tpwin=window.open(urlquery,'TestPass','width=350,height=300,center,menubar=no,scrollable=yes,resizable=yes');
}

function leapto(form) {
	var myindex=form.linkto.selectedIndex;
	location.href=(form.linkto.options[myindex].value);
}

function gotoURLpulldown(icurrent,vcurrent) {
	if (icurrent>=1) {
		window.location.href = vcurrent;
	}
	return false;
}

function checkmsrp(ms,op) {
	var jsProdPrice = ms;
	jsProdPrice = jsProdPrice.substring(1,jsProdPrice.length);
	var jsProdSaleAmount = op;
	jsProdSaleAmount = jsProdSaleAmount.substring(1,jsProdSaleAmount.length);
	var jsOnSale = jsProdPrice - jsProdSaleAmount;
	//If there is a difference of MORE THAN 10:
	if (jsOnSale > 4.99) {
		document.write('<small><b>');
		document.write("<font face='Arial'>Reg: "+ms+"</font>");
		document.write('</b></small><br>');
	}
}

function redirspecials(qs,href) {
	if(qs.length < 1) {window.location.href=href+'?061745-6628';};
}


/**
 * Gets the value of the specified cookie.
 *
 * name  Name of the desired cookie.
 *
 * Returns a string containing value of specified cookie,
 *   or null if cookie does not exist.
 */
function getCookie(name)
{
    var dc = document.cookie;
    var prefix = name + "=";
    var begin = dc.indexOf("; " + prefix);
    if (begin == -1)
    {
        begin = dc.indexOf(prefix);
        if (begin != 0) return null;
    }
    else
    {
        begin += 2;
    }
    var end = document.cookie.indexOf(";", begin);
    if (end == -1)
    {
        end = dc.length;
    }
    return unescape(dc.substring(begin + prefix.length, end));
}

/**
 * Read the JavaScript cookies tutorial at:
 *   http://www.netspade.com/articles/javascript/cookies.xml
 */

/**
 * Sets a Cookie with the given name and value.
 *
 * name       Name of the cookie
 * value      Value of the cookie
 * [expires]  Expiration date of the cookie (default: end of current session)
 * [path]     Path where the cookie is valid (default: path of calling document)
 * [domain]   Domain where the cookie is valid
 *              (default: domain of calling document)
 * [secure]   Boolean value indicating if the cookie transmission requires a
 *              secure transmission
 */
function setCookie(name, value, expires, path, domain, secure)
{
    document.cookie= name + "=" + escape(value) +
        ((expires) ? "; expires=" + expires.toGMTString() : "") +
        ((path) ? "; path=" + path : "") +
        ((domain) ? "; domain=" + domain : "") +
        ((secure) ? "; secure" : "");
}

/**
 * Deletes the specified cookie.
 *
 * name      name of the cookie
 * [path]    path of the cookie (must be same as path used to create cookie)
 * [domain]  domain of the cookie (must be same as domain used to create cookie)
 */
function deleteCookie(name, path, domain)
{
    if (getCookie(name))
    {
        document.cookie = name + "=" + 
            ((path) ? "; path=" + path : "") +
            ((domain) ? "; domain=" + domain : "") +
            "; expires=Thu, 01-Jan-70 00:00:01 GMT";
    }
}


function checkCookie() {
	oztreemenuvar=getCookie('oztreemenuvar');
	if (oztreemenuvar!=null) {
	}else{
		setCookie('oztreemenuvar','');
	}
}

function updateTreemenuvar() {
	document.treemenuform.action="http://www.outdoorsportz.com/includes/treemenu_test.html";
	document.treemenuform.submit();
}

function confirmLiveChat() {
	if (confirm("Would you like to start a live chat with Outdoor Sportz customer service?")) {
		this.newWindow = window.open('http://livechat.boldchat.com/aid/7877696274233743555/bc.chat?vr=&amp;vn=&amp;vi=&amp;url=' + escape(document.location.href), 'Chat', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1,width=640,height=480');
		this.newWindow.focus();
		this.newWindow.opener=window;
	}
	return false;	
}
// -->