
// This function generates a windows for blog

function openBlog(url) {
	popupWin = window.open(url, 'blogWin', 'width=780,height=500,status=0,scrollbars=yes,toolbar=no,resizable=yes');
	popupWin.focus();
}


function writeFooter() {
	document.write ('<tr>');
    document.write ('<td width="14"><img src="/images/webfix/footerBar_left.gif" width="14" height="20" /></td>');
    document.write ('<td id="footer"><p><a href="/aboutUs.html">About Us</a> | <a href="/links.html" id="linksBtn">Links |</a> <a href="/download.html">Press</a> | <a href="/affiliate/index.html">Affiliates</a> | <a href="/security.html">Privacy &amp; Security</a> | <a href="/warranty.html">Warranty/Return Policy</a> | <a href="/sitemap.php">Site Map</a></p></td>');
    document.write ('<td width="14"><img src="/images/webfix/footerBar_right.gif" width="14" height="20" /></td>');
    document.write ('</tr>');
    document.write ('<tr>');
    document.write ('<td>&nbsp;</td>');
    document.write ('<td style="text-align:center; padding:10px 0 5px 0;"><img src="/images/shared/footerLogos.gif" width="457" height="33" border="0" usemap="#footerLogos" />&nbsp; <a href="https://www.scanalert.com/RatingVerify?ref=www.boudoiressentials.com" target="_blank"><img width="65" height="37" border="0" src="http://images.scanalert.com/meter/www.boudoiressentials.com/31.gif" alt="HACKER SAFE certified sites prevent over 99.9% of hacker crime."></a></td>');
	document.write ('<td>&nbsp;</td>');
    document.write ('</tr>');
    document.write ('<tr>');
    document.write ('<td width="14">&nbsp;</td>');
    document.write ('<td id="legal"><p>&copy;2006-2008 Boudoir Essentials<span class="superscript">TM</span>. All Rights Reserved. <br />');
    document.write ('Boudoir Essentials, the Boudoir Essentials Design, BEparty, BEbucks, and and &quot;Who do you want to BE?&quot; are registered trademarks of <nobr>Boudoir Essentials.</nobr></p>');
    document.write ('<p>&nbsp;</p></td>');
    document.write ('<td width="14">&nbsp;</td>');
    document.write ('</tr>');
	document.write ('<map name="footerLogos" id="footerLogos">');
	document.write ('<area shape="rect" coords="79,3,185,29" href="http://www.americanexpress.com/cards/online_guarantee" target="_blank" />');
	document.write ('<area shape="rect" coords="296,-4,459,29" href="/security.html" />');
	document.write ('<area shape="rect" coords="220,1,291,27" href="http://www.bbbonline.org/cks.asp?id=1070212103249" target="_blank" />');
	document.write ('<area shape="rect" coords="-5,4,31,32" href="http://www.mastercard.com" target="_blank" />');
	document.write ('<area shape="rect" coords="38,2,79,29" href="http://www.visa.com" target="_blank" />');
	document.write ('<area shape="rect" coords="190,1,217,32" href="http://www.ups.com" target="_blank" />');
	document.write ('</map>');
}


// Used to ionsert Promo Banners into the Category Pages of the Store

function insertPromoBanner() {
	
	// Swap out specific banner info here:
	var bannerImg = "/images/promoBanners/promo_generic.gif";
	//var bannerURL = null;
	var bannerURL = "http://www.boudoiressentials.com/cgi-bin/mivavm?Merchant2/merchant.mvc+Screen=SFNT&Store_Code=BE";
	 var windowTarget = "_self";
	
	// Insert the banner into the page
	// If it is wrapped in an <a> link...
	if (bannerURL) {
		document.write ('<a href=\"' + bannerURL + '\" target=\"' + windowTarget + '\"><img src=\"' + bannerImg + '\" border=\"0\" style=\"margin: 0 0 20px 0\" /></a>');
	}
	// If it's just an image, no link...
	else {
		document.write ('<img src=\"' + bannerImg + '\" border=\"0\" style=\"margin: 0 0 20px 0\" />');
	}
}

function insertPromoBanner2() {
	document.write ('<br>');
	// Swap out specific banner info here:
	var bannerImg = "/images/promoBanners/promo_holidayGlobal.gif";
	var bannerURL = null;
	//var bannerURL = "http://www.boudoiressentials.com/cgi-bin/mivavm?Merchant2/merchant.mvc+Screen=SFNT&Store_Code=BE";
	var windowTarget = "_self";
	
	// Insert the banner into the page
	// If it is wrapped in an <a> link...
	if (bannerURL) {
		document.write ('<a href=\"' + bannerURL + '\" target=\"' + windowTarget + '\"><img src=\"' + bannerImg + '\" border=\"0\" style=\"margin: 0 0 20px 0\" /></a>');
	}
	// If it's just an image, no link...
	else {
		document.write ('<img src=\"' + bannerImg + '\" border=\"0\" style=\"margin: 0 0 20px 0\" />');
	}
}






// -------------------------------------------------------------------------------------------------------------------
// Handles the "expanding" and "collapsing" of nested ULs
// Currently used in Blog and Tips section

function updateMenu (menuName) {
	var menuTitle= (menuName + "_title");
	var menuIcon= (menuName + "_icon");
	var status = (document.getElementById(menuName).style.display);
	if (status == "none") {
		document.getElementById(menuName).style.display="block";
		document.getElementById(menuIcon).src="/images/shared/icon_expanded.gif";
	}
	else {
		document.getElementById(menuName).style.display="none";
		document.getElementById(menuIcon).src="/images/shared/icon_collapsed.gif";
	}
}



//Functions for generating different types of Pop-Open Windows for Size Charts

function openSize1() { 
	popupWin = window.open("/sizeChart/sizeChart1.html", 'sizeChart', 'width=480,height=300,status=0,scrollbars=no,toolbar=no,resizable=no');
	popupWin.focus();

}

function openSize2(url) { 
	popupWin = window.open(url, 'sizeChart', 'width=520,height=500,status=0,scrollbars=yes,toolbar=no,resizable=yes');
	popupWin.focus();

}

function openSize3(url) {
	popupWin = window.open(url, 'sizeChart', 'width=595,height=525,status=0,scrollbars=yes,toolbar=no,resizable=yes');
	popupWin.focus();
	
}


//-->

