var varpartno = " ";
var newurl = " ";
var win = null;

function bookmarksite(title, url){
if (document.all)
window.external.AddFavorite(url, title);
else if (window.sidebar)
window.sidebar.addPanel(title, url, "")
}

function wopen(url, name, w, h)
{
w += 32;
h += 96;
 var win = window.open(url,
  name, 
  'width=' + w + ', height=' + h + ', ' +
  'location=no, menubar=no, ' +
  'status=yes, toolbar=yes, scrollbars=yes, resizable=no');
 win.resizeTo(w, h);
 win.focus();
}

function NewWindow(mypage,myname,w,h,scroll)
{
LeftPosition = (screen.width) ? (screen.width-w)/2 : 0;
TopPosition = (screen.height) ? (screen.height-h)/2 : 0;
settings ='height='+h+',width='+w+',top='+TopPosition+',left='+LeftPosition+',scrollbars='+scroll+',resizable'
win = window.open(mypage,myname,settings)
win.focus();
}

function ImagesWindow(partno) {
	PopWin = ''; 
	PopWin=window.open('http://www.powersport.co.uk/showimages.php?partno='+partno, 'moreimages', 'status=no,toolbar=no,location=no,menubar=no,resizable=yes,height=572,width=765,left=10,top=10'); 
	PopWin.focus(); 
}

function OfferImagesWindow(partno) {
	PopWin = ''; 
	PopWin=window.open('http://www.powersport.co.uk/showofferimages.php?partno='+partno, 'moreimages', 'status=no,toolbar=no,location=no,menubar=no,resizable=yes,height=572,width=765,left=10,top=10'); 
	PopWin.focus(); 
}

function NewBikeWindow(make,model) {
	PopWin = ''; 
	PopWin=window.open('/motorcycles/display.php?make='+ make + '&model='+ model, 'moreimages', 'status=no,toolbar=no,location=no,menubar=no,resizable=yes,height=542,width=765,left=10,top=10'); 
	PopWin.focus(); 
}


function UsedBikeWindow(id) {
	PopWin = ''; 
	PopWin=window.open('/motorcycles/useddisp.php?id='+ id + '&no=0', 'moreimages', 'status=no,toolbar=no,location=no,menubar=no,resizable=yes,height=607,width=858,left=5,top=5'); 
	PopWin.focus(); 
}

function NewWindowHelp(mypage,myname,w,h,scroll)
{
LeftPosition = 0;
TopPosition =  0;
settings ='height='+h+',width='+w+',top='+TopPosition+',left='+LeftPosition+',scrollbars='+scroll+',resizable,toolbar=1,menubar=1,location=1'
win = window.open(mypage,myname,settings)
win.focus();
}

function NewWindowBikes(mypage,myname,w,h,scroll)
{
LeftPosition = 0;
TopPosition =  0;
settings ='height='+h+',width='+w+',top='+TopPosition+',left='+LeftPosition+',scrollbars='+scroll+',resizable=0,toolbar=1,menubar=0,location=0'
win = window.open(mypage,myname,settings)
win.focus();
}

function newwindow(varpartno)
{
var newurl="/btech/includes/07dispbigimage.php?partno="+varpartno;
window.open(newurl,'jav','width=600,height=500,alwaysRaised=yes,resizable=yes,scrollbars=no,toolbar=no,location=no,directories=no,status=no,menubar=no,copyhistory=no');

}

function imgwindow(imgloc)
{
window.open(imgloc,'jav','width=516,height=516,alwaysRaised=yes,resizable=yes,scrollbars=no,toolbar=no,location=no,directories=no,status=no,menubar=no,copyhistory=no');
}

function newwindowfree(varpartno)
{
var newurl="/btech/includes/07dispbigimagefree.php?partno="+varpartno;
window.open(newurl,'jav','width=600,height=500,alwaysRaised=yes,resizable=yes,scrollbars=no,toolbar=no,location=no,directories=no,status=no,menubar=no,copyhistory=no');

}

function fitting()
{
var newurl="/btech/includes/07fitting.html";
window.open(newurl,'jav','width=500,height=600,resizable=yes,scrollbars=yes,toolbar=no,location=no,directories=no,status=no,menubar=no,copyhistory=no,left=10,top=10');

}
