var strSearch;function bookmark(b,a){if(window.sidebar){alert("Firefox Users: Press Ctrl+D To Bookmark This Page")}else{if(navigator.userAgent.indexOf("Chrome")>=0){alert("Chrome Users: Press Ctrl+D To Bookmark This Page")}else{if(window.external){window.external.AddFavorite(a,b)}else{if(window.opera&&window.print){return true}else{alert("Press Ctrl+D To Bookmark This Page")}}}}}function insertBookmarkLink(b,a){document.write('<div class="bookmark">');if(window.opera&&window.print){document.write('<a href="'+a+'" title="'+b+'" rel="sidebar">')}else{document.write('<a href="javascript:void()" onclick="javascript:bookmark(\''+b+"','"+a+"');\">")}document.write("Bookmark This Page Now</a> to quickly and easily return to this <b>advertised special</b>.</div>")}function maximizeWindow(){window.moveTo(0,0);window.resizeTo(screen.availWidth,screen.availHeight)}function validateBarebones(){var a;for(var b=0;b<document.additem.IDOption01.length;b++){if(document.additem.IDOption01[b].checked==true){a=b;break}}var c=document.additem.IDOption01[a].value.split("|");if(c.length<2){return true}else{if(parseFloat(c[2])>0){return true}else{return window.confirm("You are about to purchase a Barebone System without a CPU, continue?")}}}function UpdatePrice(h){var d="";var b=0;var g=0;var a=document.additem.length;var e=(document.additem.prodPrice)?parseFloat(document.additem.prodPrice.value):0;var f=0;var c="http://"+window.location.host+"/catalog/viewitem.asp?ID="+h+"&O=";var k;var j;for(i=0;i<a;i++){d=document.additem.elements[i].name;b=d.indexOf("IDOption");if(b>-1){g=document.additem.elements[i].selectedIndex;if(document.additem.elements[i].checked==true){d=document.additem.elements[i].value}b=d.indexOf("|");if(b>0){k=d.split("|");d=k[2];f+=parseFloat(k[2]);e+=parseFloat(k[2]);if(k[2]>0){if(c.charAt(c.length-1)!="="){c+=","}c+=k[1]}}}}if(document.getElementById("itemPrice")){j=document.getElementById("itemPrice");j.innerHTML="Price of Advertised Item With FREE SHIPPING: $"+document.additem.basePrice.value}else{j=document.getElementById("advPrice");j.innerHTML=document.additem.basePrice.value;if(document.getElementById("currentADV")){document.getElementById("currentADV").innerHTML=document.additem.basePrice.value}}j=document.getElementById("totalPrice");j.innerHTML="$"+e.toFixed(2);if(document.getElementById("ccTotal")){document.getElementById("ccTotal").innerHTML=e.toFixed(2)}j=document.getElementById("link");j.setAttribute("href",c)}function updateBackground(c,d,a){var b=dojo.byId("group-"+c).getElementsByTagName("td");for(i=0;i<b.length;i++){b[i].style.backgroundColor="#ffffff"}for(i=1;i<=5;i++){if(dojo.byId(c+"-"+d+"-"+i)){dojo.byId(c+"-"+d+"-"+i).style.backgroundColor=a}}}function prepareMoreInfoNodes(){var a;var c;var b;a=document.getElementsByName("moreinfo");for(b=0;b<a.length;b++){dojo.connect(a[b],"onclick","showMoreInfo")}}function createMoreInfoObject(){var a;a=document.createElement("span");a.name="mi";a.id="mi";a.className="e-moreinfo";a.setAttribute("id","mi");a.setAttribute("name","mi");a.setAttribute("class","e-moreinfo");a.style.position="absolute";document.getElementsByTagName("body")[0].appendChild(a);dojo.fx.wipeOut({node:a}).play()}function showMoreInfo(b){if(!b){var b=window.event}var c=b.target.id.split("-");miLinkHover=true;switch(c[0]){case"mi":var a=window.location.protocol+"//"+window.location.host+"/catalog/option.asp?id="+c[2];window.open(a,"","height=450,width=500,scrollbars=1,resizable=0");break;case"tt":var a=window.location.protocol+"//"+window.location.host+"/catalog/techtip.asp?id="+c[1];window.open(a,"","height=450,width=500,scrollbars=1,resizable=0");break;case"it":loadInlineTip(b.target,c[1]);break}}function loadMoreInfo(a,b){dojo.xhrGet({url:"/catalog/moreinfo.asp?ID="+b,load:function(d,c){loadMoreInfoCallBack(d,a)}})}function loadTechTip(a,b){dojo.xhrGet({url:"/catalog/techtip.asp?ID="+b,load:function(d,c){loadMoreInfoCallBack(d,a)}})}function loadInlineTip(a,b){dojo.xhrGet({url:"/catalog/inlinetip.asp?ID="+b,load:function(d,c){loadMoreInfoCallBack(d,a)}})}function loadMoreInfoCallBack(a,b){dojo.byId("mi").innerHTML=a;setMoreInfoPosition(b);dojo.style(mi,"visibility","visible");dojo.fx.wipeIn({node:mi}).play()}function hideMoreInfo(){dojo.fx.wipeOut({node:mi}).play()}function setMoreInfoInvisible(){dojo.style(mi,"visibility","hidden")}function setMoreInfoPosition(k){var c=0;var n=0;var m=0;var g=0;var f=0;var b=dojo.byId("mi").offsetHeight;var j=dojo.byId("mi").offsetWidth;var h=0;var l=0;var d=0;var a=0;if(k.offsetParent){c=k.offsetLeft;n=k.offsetTop;m=k.offsetHeight;while(k=k.offsetParent){c+=k.offsetLeft;n+=k.offsetTop}}g=document.body.scrollLeft;f=document.body.scrollTop;if(self.innerWidth){l=self.innerWidth;h=self.innerHeight}else{if(document.documentElement&&document.documentElement.clientWidth){l=document.documentElement.clientWidth;h=document.documentElement.clientHeight}else{if(document.body){l=document.body.clientWidth;h=document.body.clientHeight}}}if(b>h){a=f}else{if(n+m+b>f+h){a=(f+h)-b-10}else{a=n+m}}if(c+j>g+l){d=(g+l)-j-35}else{d=c}dojo.byId("mi").style.top=a+"px";dojo.byId("mi").style.left=d+"px"}dojo.addOnLoad(prepareMoreInfoNodes);dojo.addOnLoad(createMoreInfoObject);