function showLayer(_1){obj=document.getElementById(_1);obj.style.visibility="visible";hideOtherLayers(_1);}function hideOtherLayers(_2){obj=document.getElementsByTagName("DIV");for(i=0;i<obj.length-1;i++){if((obj[i].id!=_2)&&(obj[i].id!=null)&&(obj[i].id!="")){obj[i].style.visibility="hidden";}}}function enterButton(_3){_3.bgColor="E0E0E0";}function exitButton(_4){_4.bgColor="F0F0F0";}function displayProduct(_5){document.location.href="/details.dx/sku."+_5;}function addToCart(_6,_7){obj=document.getElementById(_7);document.location.href="/shoppingcart.dx/add."+_6+"~quantity."+obj.value;}function addToCart2CO(_8,_9){obj=document.getElementById(_9);xposition=0;yposition=0;if((parseInt(navigator.appVersion)>=4)){xposition=(screen.width-600)/2;yposition=(screen.height-500)/2;}args="width=700,"+"height=500,"+"location=yes,"+"menubar=yes,"+"resizable=yes,"+"scrollbars=yes,"+"status=yes,"+"titlebar=yes,"+"toolbar=yes,"+"hotkeys=yes,"+"screenx="+xposition+","+"screeny="+yposition+","+"left="+xposition+","+"top="+yposition;window.open("https://www.2checkout.com/2co/buyer/purchase?sid=1241043&product_id=1&quantity="+obj.value,"2CO",args);}function searchResults(_a){try{if(document.getElementById("searchWithinCategory").checked){document.location.href="/products.dx/category."+document.getElementById("searchWithinCategory").value+"~search."+_a;}else{document.location.href="/search.dx/search."+_a;}}catch(error){document.location.href="/search.dx/search."+_a;}}function searchResultsOnSubmit(){obj=document.getElementById("searchBox");try{document.location.href="/search.dx/search."+obj.value;}catch(e){}}function activateCategoryTree(_b){gotoURL="/products.dx/category."+_b;SubcategoryDivID="subcategory"+_b;try{obj=document.getElementById(SubcategoryDivID);if(obj.style.display=="none"){obj.style.display="block";return;}else{obj.style.display="none";return;}}catch(e){document.location.href=gotoURL;}}function preloadimages(){var _c=new Array();for(i=0;i<preloadimages.arguments.length;i++){_c[i]=new Image();_c[i].src=preloadimages.arguments[i];}}function dynamicEnlarge(_d,_e,x,y,_xurl){version=0;if(navigator.appVersion.indexOf("MSIE")!=-1){temp=navigator.appVersion.split("MSIE");version=parseFloat(temp[1]);}if(version==0){return;}obj=document.getElementById(_d);if((_e==null)||(_e=="")){obj.innerHTML="";obj.width=0;obj.height=0;try{obj.style.visibility="hidden";}catch(ex){}}else{obj.style.visibility="visible";obj.style.left=x;obj.style.top=y;obj.width=502;obj.height=502;obj.innerHTML="<a href='"+_xurl+"'><img src='"+_e+"' border=0 alt=''></a>";}}function findPosX(_11){obj=document.getElementById(_11);var _12=0;if(obj.offsetParent){while(obj.offsetParent){_12+=obj.offsetLeft;obj=obj.offsetParent;}}else{if(obj.x){_12+=obj.x;}}return _12;}function findPosY(_13){obj=document.getElementById(_13);var _14=0;if(obj.offsetParent){while(obj.offsetParent){_14+=obj.offsetTop;obj=obj.offsetParent;}}else{if(obj.y){_14+=obj.y;}}return _14;}function switchDynamicTab(_15){obj=document.getElementById("tabButtonOverview");obj.style.backgroundColor=(obj.id==_15?"#E0E0E0":"#FFFFFF");obj.style.fontWeight=(obj.id==_15?"bold":"normal");objPage=document.getElementById("tabPageOverview");objPage.style.display=(obj.id==_15?"block":"none");obj=document.getElementById("tabButtonShipping");obj.style.backgroundColor=(obj.id==_15?"#E0E0E0":"#FFFFFF");obj.style.fontWeight=(obj.id==_15?"bold":"normal");objPage=document.getElementById("tabPageShipping");objPage.style.display=(obj.id==_15?"block":"none");obj=document.getElementById("tabButtonBulk");obj.style.backgroundColor=(obj.id==_15?"#E0E0E0":"#FFFFFF");obj.style.fontWeight=(obj.id==_15?"bold":"normal");objPage=document.getElementById("tabPageBulk");objPage.style.display=(obj.id==_15?"block":"none");}function openNewWindow(_16,_17,_18,_19,_1a,_1b){xposition=0;yposition=0;if((parseInt(navigator.appVersion)>=4)&&(_1a)){xposition=(screen.width-_18)/2;yposition=(screen.height-_19)/2;}args="width="+_18+","+"height="+_19+","+"location=0,"+"menubar=0,"+"resizable="+_1b+",scrollbars=1,"+"status=0,"+"titlebar=0,"+"toolbar=0,"+"hotkeys=0,"+"screenx="+xposition+","+"screeny="+yposition+","+"left="+xposition+","+"top="+yposition;window.open(_16,_17,args);}function processCommand(_1c){obj=document.getElementById("cmdProcessor");obj.src=_1c;}

function doHighlight(bodyText,searchTerm,highlightStartTag,highlightEndTag){
if ((!highlightStartTag)||(!highlightEndTag)){highlightStartTag=
"<font style='color:blue; background-color:yellow;'>"
;highlightEndTag=
"</font>"
;}
var newText=
""
;var i=-1;var lcSearchTerm=searchTerm.toLowerCase();var lcBodyText=bodyText.toLowerCase();while (bodyText.length>0){i=lcBodyText.indexOf(lcSearchTerm,i+1);if (i<0){newText+=bodyText;bodyText=
""
;} else {
if (bodyText.lastIndexOf(
">"
,i)>=bodyText.lastIndexOf(
"<"
,i)){
if (lcBodyText.lastIndexOf(
"/script>"
,i)>=lcBodyText.lastIndexOf(
"<script"
,i)){newText+=bodyText.substring(0,i)+highlightStartTag+bodyText.substr(i,searchTerm.length)+highlightEndTag;bodyText=bodyText.substr(i+searchTerm.length);lcBodyText=bodyText.toLowerCase();i=-1;}}}}
return newText;}
function highlightSearchTerms(searchText,treatAsPhrase,warnOnFailure,highlightStartTag,highlightEndTag){
if (treatAsPhrase){searchArray=[searchText];} else {searchArray=searchText.split(
" "
);}
if (!document.body||typeof(document.body.innerHTML)==
"undefined"
){if (warnOnFailure){alert(
"Sorry, for some reason the text of this page is unavailable. Searching will not work."
);}
return false;}
var bodyText=document.body.innerHTML;for (var i=0;i<searchArray.length;i++){bodyText=doHighlight(bodyText,searchArray[i],highlightStartTag,highlightEndTag);}
document.body.innerHTML=bodyText;return true;}
function searchPrompt(defaultText,treatAsPhrase,textColor,bgColor){
if (!defaultText){defaultText=
""
;}
if ((!textColor)||(!bgColor)){highlightStartTag=
""
;highlightEndTag=
""
;} else {highlightStartTag=
"<font style='color:"
+textColor+
"; background-color:"
+bgColor+
";'>"
;highlightEndTag=
"</font>"
;}
if (treatAsPhrase){promptText=
"Please enter the phrase you'd like to search for:"
;} else {promptText=
"Please enter the words you'd like to search for, separated by spaces:"
;}
searchText=prompt(promptText,defaultText);if (!searchText){alert(
"No search terms were entered. Exiting function."
);return false;}
return highlightSearchTerms(searchText,treatAsPhrase,true,highlightStartTag,highlightEndTag);}
function highlightGoogleSearchTerms(referrer){
if (!referrer){return false;}
var queryPrefix=
"q="
;var startPos=referrer.toLowerCase().indexOf(queryPrefix);if ((startPos>=0)&&(startPos+queryPrefix.length<referrer.length)){var endPos=referrer.indexOf(
"&"
,startPos);if (endPos<0){endPos=referrer.length;}
var queryString=referrer.substring(startPos+queryPrefix.length,endPos);
queryString=queryString.replace(
/%20/gi,
" "
);queryString=queryString.replace(
/\+/gi,
" "
);
queryString=queryString.replace(
/%22/gi,
""
);queryString=queryString.replace(
/\"/gi,
""
);return highlightSearchTerms(queryString,false);}
queryPrefix=
"search."
;var startPos=referrer.toLowerCase().lastIndexOf(queryPrefix);if ((startPos>=0)&&(startPos+queryPrefix.length<referrer.length)){var endPos=referrer.indexOf(
"~"
,startPos);if (endPos<0){endPos=referrer.length;}
var queryString=referrer.substring(startPos+queryPrefix.length,endPos);
queryString=queryString.replace(
/%20/gi,
" "
);queryString=queryString.replace(
/\+/gi,
" "
);
queryString=queryString.replace(
/%22/gi,
""
);queryString=queryString.replace(
/\"/gi,
""
);return highlightSearchTerms(queryString,false);}}
function autoHighlightSearchTerms(){highlightGoogleSearchTerms(document.URL);highlightGoogleSearchTerms(document.referrer);}

function GetCookie(_1){var _2=_1+"=";var _3=_2.length;var _4=document.cookie.length;var i=0;while(i<_4){var j=i+_3;if(document.cookie.substring(i,j)==_2){return GetCookieVal(j);}i=document.cookie.indexOf(" ",i)+1;if(i==0){break;}}return null;}function GetCookieVal(_7){var _8=document.cookie.indexOf(";",_7);if(_8==-1){_8=document.cookie.length;}return unescape(document.cookie.substring(_7,_8));}function SetCookie(_9,_a,_b){var _c=new Date();_c.setTime(_c.getTime()+_b*(24*60*60*1000));document.cookie=_9+"="+escape(_a)+"; expires="+_c.toGMTString();}

var iframeids=["forumwindow"]

var iframehide="no"

var getFFVersion=navigator.userAgent.substring(navigator.userAgent.indexOf("Firefox")).split("/")[1]
var FFextraHeight=parseFloat(getFFVersion)>=0.1? 16 : 0 //extra height in px to add to iframe in FireFox 1.0+ browsers

function resizeCaller() {
var dyniframe=new Array()
for (i=0; i<iframeids.length; i++){
if (document.getElementById)
resizeIframe(iframeids[i])
//reveal iframe for lower end browsers? (see var above):
if ((document.all || document.getElementById) && iframehide=="no"){
var tempobj=document.all? document.all[iframeids[i]] : document.getElementById(iframeids[i])
if (tempobj)
tempobj.style.display="block"
}
}
}

function resizeIframe(frameid){
var currentfr=document.getElementById(frameid)
if (!currentfr) return;
if (currentfr && !window.opera){
currentfr.style.display="block"
if (currentfr.contentDocument && currentfr.contentDocument.body.offsetHeight) //ns6 syntax
currentfr.height = currentfr.contentDocument.body.offsetHeight+FFextraHeight; 
else if (currentfr.Document && currentfr.Document.body.scrollHeight) //ie5+ syntax
currentfr.height = currentfr.Document.body.scrollHeight;
if (currentfr.height<=500) currentfr.height = 500;
if (currentfr.addEventListener)
currentfr.addEventListener("load", readjustIframe, false)
else if (currentfr.attachEvent){
currentfr.detachEvent("onload", readjustIframe) // Bug fix line
currentfr.attachEvent("onload", readjustIframe)
}
}
}

function readjustIframe(loadevt) {
var crossevt=(window.event)? event : loadevt
var iframeroot=(crossevt.currentTarget)? crossevt.currentTarget : crossevt.srcElement
if (iframeroot)
resizeIframe(iframeroot.id);
}

function loadintoIframe(iframeid, url){
if (document.getElementById)
document.getElementById(iframeid).src=url
}


if (window.addEventListener)
window.addEventListener("load", resizeCaller, false)
else if (window.attachEvent)
window.attachEvent("onload", resizeCaller)
else
window.onload=resizeCaller
