     function BADenlargePhoto(p,e) {
		newwindow=window.open('gallery_photo.php?p='+p+'&l='+e+'&t=3','name','height=500,width=760,toolbar=no,menubar=no,location=no,scrollbars=yes,resizable=yes');
	 }

function openCvc2() {
	window.open("cvc2.php","NewWindow","WIDTH=400,HEIGHT=400,toolbar=no,menubar=no,location=no,scrollbars=yes,resizable=yes");
}
function openHelp() {
	window.open("http://www.bethsbabies.com/help.php","NewWindow","WIDTH=600,HEIGHT=500,toolbar=no,menubar=no,location=no,scrollbars=yes,resizable=yes");
}

function openShipMethods() {
	window.open("shipping_method_p.php","NewWindow","WIDTH=400,HEIGHT=400,toolbar=no,menubar=no,location=no,scrollbars=yes,resizable=yes");
}

function changeFieldValue(fieldNum,offVar) {
	document.chkfrm[fieldNum].value = offVar;
}


function redirectMe(strURL) {
document.location=strURL;  
}
function UpdateQty(item)
{
	itemId = item.name;
	newQty = item.options[item.selectedIndex].text;
	
	document.location.href = 'store_cart.php?v=2&vc='+itemId+'&vq='+newQty;

}

var DHTML = (document.getElementById || document.all || document.layers);

function swap(flag,lid)
{
	if (!DHTML) return;
	var x = new getLayerObj(lid);
	x.style.visibility = (flag) ? 'visible' : 'hidden';
}

function resizeDiv(lid,amt) {

	var x = new getLayerObj(lid);
	x.style.height = amt + 'px';

}
function getLayerObj(name) {
  if (document.getElementById)  {
  	this.obj = document.getElementById(name);
	this.style = document.getElementById(name).style;
  }
  else if (document.all)  {
	this.obj = document.all[name];
	this.style = document.all[name].style;
  }
  else if (document.layers)  {
   	this.obj = document.layers[name];
   	this.style = document.layers[name];
  }
}


function changeLayerBgColor(lid,col)
{
	if (!DHTML) return;
	var x = new getLayerObj(lid);
	x.style.backgroundColor = col;
}

function updateDivContent(lid,contentHTML) {
document.getElementById(lid).innerHTML=contentHTML;
}
function submitOnce(theform){
if (document.all||document.getElementById){
for (i=0;i<theform.length;i++){
var tempobj=theform.elements[i]
if(tempobj.type.toLowerCase()=="submit"||tempobj.type.toLowerCase()=="reset")
tempobj.disabled=true
}
}
}
