
var IEPNGFix=window.IEPNGFix||{};IEPNGFix.tileBG=function(elm,pngSrc,ready){var data=this.data[elm.uniqueID],elmW=Math.max(elm.clientWidth,elm.scrollWidth),elmH=Math.max(elm.clientHeight,elm.scrollHeight),bgX=elm.currentStyle.backgroundPositionX,bgY=elm.currentStyle.backgroundPositionY,bgR=elm.currentStyle.backgroundRepeat;if(!data.tiles){data.tiles={elm:elm,src:'',cache:[],img:new Image(),old:{}};}
var tiles=data.tiles,pngW=tiles.img.width,pngH=tiles.img.height;if(pngSrc){if(!ready&&pngSrc!=tiles.src){tiles.img.onload=function(){this.onload=null;IEPNGFix.tileBG(elm,pngSrc,1);};return tiles.img.src=pngSrc;}}else{if(tiles.src)ready=1;pngW=pngH=0;}
tiles.src=pngSrc;if(!ready&&elmW==tiles.old.w&&elmH==tiles.old.h&&bgX==tiles.old.x&&bgY==tiles.old.y&&bgR==tiles.old.r){return;}
var pos={top:'0%',left:'0%',center:'50%',bottom:'100%',right:'100%'},x,y,pc;x=pos[bgX]||bgX;y=pos[bgY]||bgY;if(pc=x.match(/(\d+)%/)){x=Math.round((elmW-pngW)*(parseInt(pc[1])/100));}
if(pc=y.match(/(\d+)%/)){y=Math.round((elmH-pngH)*(parseInt(pc[1])/100));}
x=parseInt(x);y=parseInt(y);var repeatX={'repeat':1,'repeat-x':1}[bgR],repeatY={'repeat':1,'repeat-y':1}[bgR];if(repeatX){x%=pngW;if(x>0)x-=pngW;}
if(repeatY){y%=pngH;if(y>0)y-=pngH;}
this.hook.enabled=0;if(!({relative:1,absolute:1}[elm.currentStyle.position])){elm.style.position='relative';}
var count=0,xPos,maxX=repeatX?elmW:x+0.1,yPos,maxY=repeatY?elmH:y+0.1,d,s,isNew;if(pngW&&pngH){for(xPos=x;xPos<maxX;xPos+=pngW){for(yPos=y;yPos<maxY;yPos+=pngH){isNew=0;if(!tiles.cache[count]){tiles.cache[count]=document.createElement('div');isNew=1;}
var clipR=Math.max(0,xPos+pngW>elmW?elmW-xPos:pngW),clipB=Math.max(0,yPos+pngH>elmH?elmH-yPos:pngH);d=tiles.cache[count];s=d.style;s.behavior='none';s.left=(xPos-parseInt(elm.currentStyle.paddingLeft))+'px';s.top=yPos+'px';s.width=clipR+'px';s.height=clipB+'px';s.clip='rect('+
(yPos<0?0-yPos:0)+'px,'+
clipR+'px,'+
clipB+'px,'+
(xPos<0?0-xPos:0)+'px)';s.display='block';if(isNew){s.position='absolute';s.zIndex=-999;if(elm.firstChild){elm.insertBefore(d,elm.firstChild);}else{elm.appendChild(d);}}
this.fix(d,pngSrc,0);count++;}}}
while(count<tiles.cache.length){this.fix(tiles.cache[count],'',0);tiles.cache[count++].style.display='none';}
this.hook.enabled=1;tiles.old={w:elmW,h:elmH,x:bgX,y:bgY,r:bgR};};IEPNGFix.update=function(){for(var i in IEPNGFix.data){var t=IEPNGFix.data[i].tiles;if(t&&t.elm&&t.src){IEPNGFix.tileBG(t.elm,t.src);}}};IEPNGFix.update.timer=0;if(window.attachEvent&&!window.opera){window.attachEvent('onresize',function(){clearTimeout(IEPNGFix.update.timer);IEPNGFix.update.timer=setTimeout(IEPNGFix.update,100);});}
function MM_preloadImages(){var d=document;if(d.images){if(!d.MM_p)d.MM_p=new Array();var i,j=d.MM_p.length,a=MM_preloadImages.arguments;for(i=0;i<a.length;i++)
if(a[i].indexOf("#")!=0){d.MM_p[j]=new Image;d.MM_p[j++].src=a[i];}}}
function MM_swapImgRestore(){var i,x,a=document.MM_sr;for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++)x.src=x.oSrc;}
function MM_findObj(n,d){var p,i,x;if(!d)d=document;if((p=n.indexOf("?"))>0&&parent.frames.length){d=parent.frames[n.substring(p+1)].document;n=n.substring(0,p);}
if(!(x=d[n])&&d.all)x=d.all[n];for(i=0;!x&&i<d.forms.length;i++)x=d.forms[i][n];for(i=0;!x&&d.layers&&i<d.layers.length;i++)x=MM_findObj(n,d.layers[i].document);if(!x&&document.getElementById)x=document.getElementById(n);return x;}
function MM_swapImage(){var i,j=0,x,a=MM_swapImage.arguments;document.MM_sr=new Array;for(i=0;i<(a.length-2);i+=3)
if((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x;if(!x.oSrc)x.oSrc=x.src;x.src=a[i+2];}}
if(navigator.appName=='Netscape'){var browser='NS';var version=(navigator.appVersion);}
if(navigator.appName=='Microsoft Internet Explorer'){var browser='IE';var version=(navigator.appVersion);}
NS4=(document.layers)?1:0;NS6=((browser=='NS')&&(document.getElementById))?1:0;var agent=navigator.userAgent.toLowerCase();opera=(agent.indexOf("opera")!=-1)?true:false
macs=(agent.indexOf("mac")!=-1)?true:false
function MM_showHideLayers(){var i,p,v,obj,args=MM_showHideLayers.arguments;for(i=0;i<(args.length-2);i+=3)if((obj=MM_findObj(args[i]))!=null){v=args[i+2];if(obj.style){obj=obj.style;v=(v=='show')?'visible':(v=='hide')?'hidden':v;}
obj.visibility=v;}}
function showHideLayersNS(layerName,actions){if(NS4){document.layers[layerName].visibility=actions;}
else{document.getElementById(layerName).style.visibility=actions;}}
function popupWindow(url,name,width,height){newwindow=window.open(url,name,"width="+width+",height="+height+",toolbar=0,directories=0,menubar=0,status=0,resizable=1,location=0,scrollbars=1,copyhistory=0,left=162,top=200");if(newwindow){newwindow.window.focus();}
else{window.alert('You may have popup blocking software running on your browser that is preventing you from viewing content or using functionality of the site.\nTo avoid this from happening temporarily disable your popup blocking software.');}}
function popupWindow2(url,name,width,height){newwindow2=window.open(url,name,"width="+width+",height="+height+",toolbar=0,directories=0,menubar=0,status=0,resizable=1,location=0,scrollbars=1,copyhistory=0,left=162,top=200");newwindow2.window.focus();}
function popupWindow3(url,name,width,height){newwindow3=window.open(url,name,"width="+width+",height="+height+",toolbar=0,directories=0,menubar=0,status=0,resizable=1,location=0,scrollbars=1,copyhistory=0,left=162,top=200");newwindow3.window.focus();}
function popupWindowNoScroll(url,name,width,height){newwindow4=window.open(url,name,"width="+width+",height="+height+",toolbar=0,directories=0,menubar=0,status=0,resizable=0,location=0,scrollbars=0,copyhistory=0,left=162,top=200");newwindow4.focus();}
function popupWindowScroll(url,name,width,height){newwindow=window.open(url,name,"width="+width+",height="+height+",toolbar=0,directories=0,menubar=0,status=0,resizable=1,location=0,scrollbars=1,copyhistory=0,left=162,top=200");newwindow.window.focus();}
function popupWindowNoScrollPos(url,name,width,height,left,top){newwindow=window.open(url,name,"width="+width+",height="+height+",toolbar=0,directories=0,menubar=0,status=0,resizable=0,location=0,scrollbars=0,copyhistory=0,left="+left+",top="+top+"");newwindow.window.focus();}
function popupWindowScrollPos(url,name,width,height,left,top,resize){newwindow=window.open(url,name,"width="+width+",height="+height+",toolbar=0,directories=0,menubar=0,status=0,resizable="+resize+",location=0,scrollbars=1,copyhistory=0,left="+left+",top="+top+"");newwindow.window.focus();}
function popupWindowAdminWin(url){newwindow=window.open(url,'MAINADMINWIN',"width=785,height=540,toolbar=0,directories=0,menubar=0,status=0,resizable=1,location=0,scrollbars=1,copyhistory=0,left=10,top=10");newwindow.window.focus();}
function generalPopup(url,name,width,height,left,top,resize,tool,menu,directories,status,location,scrollbars,history){generalwindow=window.open(url,name,"width="+width+",height="+height+",toolbar="+tool+",directories="+directories+",menubar="+menu+",status="+status+",resizable="+resize+",location="+location+",scrollbars="+scrollbars+",copyhistory="+history+",left="+left+",top="+top+"");generalwindow.window.focus();}
function closeThisOpenThat(redirectUrl){parent.opener.location=redirectUrl;self.close();}
function MM_jumpMenu(targ,selObj,restore){eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");if(restore)selObj.selectedIndex=0;}
function MM_jumpMenuInNew(selObj,restore){var url='http://'+selObj.options[selObj.selectedIndex].value;PCD=window.open(url,'');PCD.window.focus();if(restore)selObj.selectedIndex=0;}
function MM_reloadPage(init){if(init==true)with(navigator){if((appName=="Netscape")&&(parseInt(appVersion)==4)){document.MM_pgW=innerWidth;document.MM_pgH=innerHeight;onresize=MM_reloadPage;}}
else if(innerWidth!=document.MM_pgW||innerHeight!=document.MM_pgH)location.reload();}
MM_reloadPage(true);var cookiesaloud
function checkcookies(){if(document.cookie.length>0){cookiesaloud=1}
else{cookiesaloud=0}}
function openBrWindow(theURL,winName,features){window.open(theURL,winName,features);}
function changeClass(cellid,strNewClass){if((!macs)&&(!NS4)){document.getElementById(cellid).className=strNewClass;}}
function setNaviState(strpage){if(strpage!=""){if(!NS4){changeClass(strpage,"currentLink");}}}
function hideDDs(){if(browser=="NS"){showHideLayersNS("sortByDiv","hidden");}
if(browser!="NS"){if(document.getElementById('sortByDiv')){document.getElementById('sortByDiv').style.visibility="hidden";}}}
function showDDs(){if(browser=="NS"){showHideLayersNS("sortByDiv","visible");}
if(browser!="NS"){if(document.getElementById('sortByDiv')){document.getElementById('sortByDiv').style.visibility="visible";}}}
function setImageSize(maxImgHeight,maxImgWidth){var thumbPrefix="thumb_";var maxWidth=maxImgWidth,maxHeight=maxImgHeight;if(document.images){for(var loopCounter=0;loopCounter<document.images.length;loopCounter++){if(document.images[loopCounter].id.substring(0,thumbPrefix.length)==thumbPrefix){if(document.images[loopCounter].width>maxWidth)
document.images[loopCounter].width=maxWidth;if(document.images[loopCounter].height>maxHeight)
document.images[loopCounter].height=maxHeight;}}}}
function sendContactEMail(box){var strDom="venturesport.co.uk"
var strBox=box
document.location.href="mailto:"+strBox+"@"+strDom}
function limitImageWidth(imageID,limitWidth){if(document.images[imageID].width>limitWidth){document.images[imageID].width=limitWidth;}}
function limitImageHeight(imageID,limitHeight){if(document.images[imageID].height>limitHeight){document.images[imageID].height=limitHeight;}}
var tempX=0
var tempY=0
var IE
function startMouseCapture(){IE=document.all?true:false
if(!IE)document.captureEvents(Event.MOUSEMOVE)
document.onmousemove=getMouseXY;}
function getMouseXY(e){if(IE){tempX=event.clientX+document.body.scrollLeft
tempY=event.clientY+document.body.scrollTop}else{tempX=e.pageX
tempY=e.pageY}
if(tempX<0){tempX=0}
if(tempY<0){tempY=0}
return true}
var movetimeout;var locktimeout;function reposition(object,newx,newy){object.style.top=newy+"px";object.style.left=newx+"px";}
function lockToCursor(strObject){clearTimeout(locktimeout)
var object=document.getElementById(strObject);object.style.position="absolute"
object.style.top=parseInt(tempY)+10+"px";object.style.left=parseInt(tempX)+10+"px";locktimeout=setTimeout("lockToCursor('"+strObject+"')",20)}
function animatedReposition(id,newx,newy){object=document.getElementById(id);clearTimeout(movetimeout);curx=parseInt(object.style.top);cury=parseInt(object.style.left);diffx=0;diffy=0;if(curx<newx){diffx=newx-curx;}else{diffx=curx-newx;}
if(cury<newy){diffy=newy-cury;}else{diffy=cury-newy;}
ysubstep=false;step=0;substep=0;if(diffx<diffy){step=diffy;substep=step/diffx;}else if(diffx>diffy){step=diffx;substep=step/diffy;ysubstep=true;}
i=0;if(ysubstep){if(parseInt(object.style.top)<newx){object.style.top=(parseInt(object.style.top)+1)+"px";}else if(parseInt(object.style.top)>newx){object.style.top=(parseInt(object.style.top)-1)+"px";}
if(parseInt(object.style.left)<newy){object.style.left=(parseInt(object.style.left)+substep)+"px";}else if(parseInt(object.style.left)>newy){object.style.left=(parseInt(object.style.left)-substep)+"px";}}else{if(parseInt(object.style.top)<newx){object.style.top=(parseInt(object.style.top)+substep)+"px";}else if(parseInt(object.style.top)>newx){object.style.top=(parseInt(object.style.top)-substep)+"px";}
if(parseInt(object.style.left)<newy){object.style.left=(parseInt(object.style.left)+1)+"px";}else if(parseInt(object.style.left)>newy){object.style.left=(parseInt(object.style.left)-1)+"px";}}
if((parseInt(object.style.top)!=newx)&&(parseInt(object.style.left)!=newy)){setTimeout("animatedReposition ('"+id+"', "+newx+", "+newy+")",20)}}
var intBasketstate=0;function toggle_basket(){if(intBasketstate==1){intBasketstate=0;document.getElementById("basket_tab").style.display='none';document.getElementById("brands_dd").style.display="block";}else{intBasketstate=1;document.getElementById("basket_tab").style.display='block';document.getElementById("basket_tab").style.top='25px';document.getElementById("basket_tab").style.left=(parseInt(document.body.scrollWidth)-350)+"px";document.getElementById("brands_dd").style.display="none";}}
function overlib(strImg,ext1,ext2,ext3,ext4,ext5,ext6){document.getElementById('fakeoverlibdiv').innerHTML=strImg;document.getElementById('fakeoverlibdiv').style.display="block"
startMouseCapture();lockToCursor('fakeoverlibdiv')}
function nd(){clearTimeout(locktimeout)
document.getElementById('fakeoverlibdiv').style.display="none";}
sfHover=function(){var sfEls=document.getElementById("nav").getElementsByTagName("LI");for(var i=0;i<sfEls.length;i++){sfEls[i].onmouseover=function(){this.className+=" sfhover";}
sfEls[i].onmouseout=function(){this.className=this.className.replace(new RegExp(" sfhover\\b"),"");}}}
if(window.attachEvent)window.attachEvent("onload",sfHover);cnHover=function(){var sfEls=document.getElementById("ddnav").getElementsByTagName("LI");for(var i=0;i<sfEls.length;i++){sfEls[i].onmouseover=function(){this.className+=" cnHover";}
sfEls[i].onmouseout=function(){this.className=this.className.replace(new RegExp(" cnHover\\b"),"");}}}
if(window.attachEvent)window.attachEvent("onload",cnHover);var bufferid
bufferid=-1
var timeoutid
var intoffsetx=150;var intoffsety=0;function findPosX(obj)
{var curleft=0;if(obj){if(obj.offsetParent)
{while(obj.offsetParent)
{curleft+=obj.offsetLeft
obj=obj.offsetParent;}}
else if(obj.x)
curleft+=obj.x;}
curleft+=intoffsetx
return curleft;}
function findPosY(obj)
{var curtop=0;if(obj){if(obj.offsetParent)
{while(obj.offsetParent)
{curtop+=obj.offsetTop
obj=obj.offsetParent;}}
else if(obj.y)
curtop+=obj.y;curtop+=5}
curtop+=intoffsety
return curtop;}
function moreinfo_enter(o){if(o){document.getElementById('Menu1000000').style.top=findPosY(o)-300+"px";document.getElementById('Menu1000000').style.left=findPosX(o)-150+"px";}
document.getElementById('Menu1000000').style.visibility="visible";document.getElementById('Menu1000000').style.display="block";}
function moreinfo_exit(){if(bufferid!="Menu1000000"){timeoutid=setTimeout(moreinfo_hide,300);}}
function moreinfo_hide(){document.getElementById('Menu1000000').style.display="none";bufferid=-1;}
