if(document.layers){
_browser="nn"}
if(document.all){
_browser="ie"}
if(navigator.userAgent.toLowerCase().match("gecko")){
_browser="gecko"}

function isEmail(str) {
   return ((str.indexOf("@") > 0));
}



function delay(gap){
var then,now
then=new Date().getTime()
now=then
while((now-then)<gap){
now=new Date().getTime()}}
function OnButton(bt){
document.images[bt].src=skin_images+bt+"_on.gif"}
function OffButton(bt){
document.images[bt].src=skin_images+bt+"_off.gif"}
function OnMenu(cid){
document.images["menul_"+cid].src=skin_images+"catl_bg_on.gif"
document.all["menur_"+cid].background=skin_images+"catr_bg_on.gif"}
function OffMenu(cid){
document.images["menul_"+cid].src=skin_images+"catl_bg_off.gif"
document.all["menur_"+cid].background=skin_images+"catr_bg_off.gif"}
var RecentTimeOut,CartTimeOut
function ShowCart(){
window.clearTimeout(CartTimeOut)
if(_browser=="ie"){
cartDiv.style.visibility=
cartDiv.style.visibility=="hidden"?"visible":"hidden"
document.images["cartImage"].src=
cartDiv.style.visibility=="hidden"?
(skin_images+"ic_expand.gif"):
(skin_images+"ic_collapse.gif")}
else if(_browser=="gecko"){
document.getElementById('cartDiv').style.visibility=
document.getElementById('cartDiv').style.visibility=="hidden"?"visible":"hidden"
document.images["cartImage"].src=
document.getElementById('cartDiv').style.visibility=="hidden"?
(skin_images+"ic_expand.gif"):
(skin_images+"ic_collapse.gif")}
else{
document.cartDiv.visibility=document.cartDiv.visibility=="hidden"?"visible":"hidden"}}
function ShowRecent(){
window.clearTimeout(RecentTimeOut)
if(_browser=="ie"){
recentDiv.style.visibility=
recentDiv.style.visibility=="hidden"?"visible":"hidden"
document.images["recentImage"].src=
recentDiv.style.visibility=="hidden"?
(skin_images+"ic_expand.gif"):
(skin_images+"ic_collapse.gif")}
else if(_browser=="gecko"){
document.getElementById('recentDiv').style.visibility=
document.getElementById('recentDiv').style.visibility=="hidden"?"visible":"hidden"
document.images["recentImage"].src=
document.getElementById('recentDiv').style.visibility=="hidden"?
(skin_images+"ic_expand.gif"):
(skin_images+"ic_collapse.gif")}
else{
document.recentDiv.visibility=document.recentDiv.visibility=="hidden"?"visible":"hidden"}}
function PopUpCart(){
CartTimeOut=window.setTimeout('ShowCart();',1000)}
function PopUpRecent(){
RecentTimeOut=window.setTimeout('ShowRecent();',1000)}
function OnMenu(img){
document.images[img].src=skin_images+"menu_arrow_on.gif"}
function OffMenu(img){
document.images[img].src=skin_images+"menu_arrow.gif"}

function ShowPopup(src){
var bWin=null
bWin=window.open(
src,
"PopupWind",
"titlebar=no, toolbar=no, menubar=no, status=no, directories=no, resizable=no, scrollbars=no, top=20, left=20, width=320, height=240"
)
while(bWin==null)
bWin.focus()}

function PopUpImage(image_source,image_width,image_height){
var bWin=null
bWin=window.open(
image_source,
"ImageWind",
"titlebar=no, toolbar=no, menubar=no, status=no, directories=no, resizable=no, scrollbars=no, top=20, left=20, width="+(image_width+20)+", height="+(image_height+20)
)
while(bWin==null)
bWin.focus()}

function PopUpWindow(src,width,height){
var bWin=null
bWin=window.open(
src,
"ImageWind",
"titlebar=no, toolbar=no, menubar=no, status=no, directories=no, resizable=no, scrollbars=no, top=20, left=20, width="+(width)+", height="+(height)
)
while(bWin==null)
bWin.focus()}
function ShowHideProdDetails(){
	el = document.getElementById("dvProdDetails");
	el.style.display = el.style.display == "none"?"block":"none";
}
function ShowHideNewAddress(){
	el = document.getElementById("dvNewAddress");
	el.style.display = el.style.display == "none"?"block":"none";
}

