<!--
// sniff browser
var browser;
if(document.getElementById){browser="NN6";}
if(document.all){browser="IE";}
if(document.layers){browser="NN4";}

function MM_findObj(n, d) { //v4.01
  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 && d.getElementById) x=d.getElementById(n); return x;
}

function MM_showHideLayers() { //v6.0
  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 swapimage(imgname,image){
  if(document.images){
    eval("document."+imgname+".src='/drivewise/drivewise_db/images/"+image+"'");
  }
}

// open child window
function openWin(theURL,winName,winSize){
  if(window.winName&&!winName.closed){
	window.winName.location = theURL;
    }else{
      winName=window.open(theURL,winName,winSize);
  }
}

// open vehicle image window
function img_win(image,testID){
  if(window.piccy&&!piccy.closed){
    piccy.focus();
  } piccy=window.open('http://www.lpdriver.co.uk/201244_Webfiles/reviews/detail.asp?image='+image+'&testID='+testID,"pic",'resizable=0,width=505,height=338');
}

// open map window
function showMap(dealerID){
  if(window.piccy&&!piccy.closed){
    piccy.focus();
  }
  piccy=window.open("loc_map.asp?dealerID="+dealerID,"pic",'resizable=0,width=550,height=500,menubar=yes');
}
//-->
