//REPLACE L, G, K, Y, P, W, R, //change all function names function loadxy65() { //next line, omit var and it becomes a global array (use xy=[ not var xy=[ ) xy = [ ["",0,0] ,["6501G3346/E 10KT YELL",133,458] ,["6501JVJ3958 10KT Y&W",292,471] ,["6502G3085/E 10KT YELL",78,94] ,["6502G3358/P 10KT YELL",167,108] ,["6502G2860/E 10KT YELL",247,82] ,["6502G3209/P 10KT YELL",355,93] ,["6502JVJ3781 10KT YELL",304,156] ,["6502ICG2079P0610KT W&PK",292,321] ,["6502ICG2079E0610KT W&PK",372,325] ,["6502G2538/P 10KT W&PK",80,490] ,["6502ICG2629P0210KT PK&W",180,492] ,["6502JVJ3950 10KT WG",98,564] ,["6502JVJ3758 10KT WG",213,565] ,["6502JVJ3756 10KT W&PK",349,543] ,["6502G3285/P 10KT YELL",596,84] ,["6502G3360/P 10KT YELL",517,157] ,["6502ICJ3793/0210KT YELL",548,252] ,["6502ICG3287P0210KT WG",730,157] ,["6502G3353/P 10KT WG",809,115] ,["6502JVJ3890 10KT WG",741,471] ,["6502JVJ3536 10KT YELL",786,524] ,["6502JVJ3917 10KT WG",775,575] ,["6503G3232P/WH 10KT PINK",91,102] ,["6503ICJ3908/0210KT PINK",141,163] ,["6503G3341/P 10KT YWP",259,115] ,["6503G3227/P 10KT W/Y/P",349,83] ,["6503JVJ3914 10KT WYP",358,149] ,["6503ICJ3922/0910KT W&PK",138,486] ,["6503ICJ3940/0910KT W&PK",112,555] ,["6503G3383E/PTZ10KT YELL",303,417] ,["6503G3383P/PTZ10KT YELL",382,402] ,["6503G3362P/PTZ10KT PINK",279,513] ,["6503G3126P/MTZ10KT WG",370,523] ,["6503JVJ3667MTZ10KT WG",314,605] ,["6503G3310/P 10KT YELL",529,104] ,["6503G3310/E 10KT YELL",573,157] ,["6503G3342/E 10KT WG",735,86] ,["6503G3342/P 10KT WG",809,84] ,["6503G3306/E 10KT Y&W",527,274] ,["6503G3306/P 10KT Y&W",607,275] ,["6503JVJ3916 10KT Y&W",562,387] ,["6503ICG3364P0610KT WG",719,324] ,["6503FIG3364E1210KT WG",786,336] ,["6503JVJ3886 10KT YELL",549,491] ,["6503ICJ3517/0210KT WG",573,555] ,["6503JVJ3782 10KT WG",753,461] ,["6503JVJ3760 10KT YELL",797,523] ,["6503JVJ2194 10KT YELL",763,593] ,["6504ICJ3236/0310KT WG",102,98] ,["6504ICJ3236/W 10KT WG",123,147] ,["6504ICJ3235/0310KT WG",238,44] ,["6504ICJ3235/W 10KT WG",238,84] ,["6504ICJ3248/0410KT WG",371,118] ,["6504ICJ3248/W 10KT WG",358,158] ,["6504ICJ3825/0510KT Y&W",236,167] ,["6504ICJ3825/W 10KT Y&W",234,204] ,["6504ICJ3959/3014KT WG",100,253] ,["6504ICJ3956/3014KT YELL",348,271] ,["6504ICJ3732/7014KT Y&W",157,377] ,["6504ICJ3571/5014KT WG",292,384] ,["6504ICG3372P1410KT YELL",60,575] ,["6504ICG3084P0510KT W&Y",135,556] ,["6504ICG2891P0510KT YELL",202,575] ,["6504ICG3034P0510KT W&PK",302,505] ,["6504ICG2897P1410KT WG",372,492] ,["6504ICJ3913/0910KT PINK",734,64] ,["6504ICJ3913/1110KT YELL",796,115] ,["6504ICJ3913/1410KT WG",754,168] ,["6504G3309P/R 10KT YELL",505,86] ,["6504G3309E/R 10KT YELL",574,84] ,["6504JVJ3939/R 10KT YELL",517,262] ,["6504JVJ3688/CT10KT YELL",594,292] ,["6504G3108P/GA 10KT YELL",504,492] ,["6504JVJ3656/GA10KT YELL",595,522] ,["6504JVJ3823/R 10KT YELL",528,575] ,["6504JVJ3300/1010KT WG",719,534] ,["6504JVJ3300/1510KT WG",9999,9999] ,["6504JVJ3300/2010KT WG",9999,9999] ,["6504JVJ3300/2514KT YELL",800,564] ,["6504JVJ3300/3314KT YELL",9999,9999] ,["6504JVJ3300/5014KT YELL",9999,9999] ,["6504JVJ3300/7514KT YELL",9999,9999] ,["6504JVJ3300/0014KT YELL",9999,9999] ,["6505G3370P/R 10KT YELL",104,439] ,["6505G3370E/R 10KT YELL",202,429] ,["6505JVJ3955/R 10KT YELL",327,450] ]; } //for mouseover on flyer for price function xyp65(book) { var x,y; var zoom = document.documentElement.clientWidth / window.innerWidth; x=(mouse_x/zoom)-(document.getElementById("div621").offsetLeft/zoom); //mobile version shifts first page of flyer when showing spreads if (flyershown.substr(2,2)=="01") { if (isMobileDevice) { x=x; }else{ x=x-parseInt(document.getElementById("div621").style.width)/2; } }else{ if (isMobileDevice) { if (isOdd(Number(flyershown.substr(2,2)))) { x=x+parseInt(document.getElementById("div621").style.width); } } } //if (flyershown.substr(2,2)=="01") { x=x-parseInt(document.getElementById("div621").style.width)/2; } x=x/0.95; x=x/(document.getElementById("flyer_ndx").width/zoom)*230; //ok to use flyer_ndx becuase that was how it was scaled y=mouse_y-document.getElementById("div620").offsetTop; y=y/(parseInt(document.getElementById("div621").style.height))*675; y=y/zoom; var minx=0; var fs=flyershown; if (isMobileDevice) { fs=Number(flyershown.substr(2,2)); fs=Math.floor(fs/2)+1; fs="0"+fs; fs=flyershown.substr(0,2)+fs.substr(fs.length-2,2); //need to convert pages to spreads } for (i=0; i0) { update_price(xy[minx][0].substr(4,10),xy[minx][0].substr(14,10)); var xypr=document.getElementById("i8").innerHTML.split(';')[1]; //everything after the first ; xypr=xypr+"<"; xypr=xypr.substring(0, xypr.indexOf("<")); //everything before the first < document.getElementById("flyer_overlay_txt").innerHTML = "
$"+xypr+"
"+"click for details
" y=xy[minx][2]*zoom; //y=y*(document.getElementById("flyer_spread").height)/675; y=y*(parseInt(document.getElementById("div621").style.height))/675; y=y+document.getElementById("div620").offsetTop; x=xy[minx][1]*(document.getElementById("flyer_ndx").width/zoom)/230; x=x+(document.getElementById("div621").offsetLeft/zoom); if (flyershown.substr(2,2)=="01") { x=x+parseInt(document.getElementById("div621").style.width)/2; } x=x*0.95; //entire spread reduced to 95% to show flip effect x=x+30; //move over beside image //if too close to right side, show at left //else show on right //x=x-25-50; if (x<0) { x=0; } //y=y-25; if (y<0) { y=0; } document.getElementById("flyer_overlay").style.left=x+"px"; document.getElementById("flyer_overlay").style.top=y+"px"; document.getElementById("flyer_overlay").style.display = "block"; }else{ document.getElementById("flyer_overlay").style.display = "none"; } //alert("done overlay"); } //calls ItemDetail from touch position on flyer function xy65(book) { //alert('book='+book); var x,y; var zoom = document.documentElement.clientWidth / window.innerWidth; x=(mouse_x/zoom)-(document.getElementById("div621").offsetLeft/zoom); //mobile version shifts first page of flyer when showing spreads if (flyershown.substr(2,2)=="01") { if (isMobileDevice) { x=x; }else{ x=x-parseInt(document.getElementById("div621").style.width)/2; } }else{ if (isMobileDevice) { if (isOdd(Number(flyershown.substr(2,2)))) { x=x+parseInt(document.getElementById("div621").style.width); } } } //if (flyershown.substr(2,2)=="01") { x=x-parseInt(document.getElementById("div621").style.width)/2; } x=x/0.95; y=mouse_y-document.getElementById("div620").offsetTop; x=x/(document.getElementById("flyer_ndx").width/zoom)*230; //ok to use flyer_ndx becuase that was how it was scaled y=y/(parseInt(document.getElementById("div621").style.height))*675; y=y/zoom; var minx=0; var fs=flyershown; if (isMobileDevice) { fs=Number(flyershown.substr(2,2)); fs=Math.floor(fs/2)+1; fs="0"+fs; fs=flyershown.substr(0,2)+fs.substr(fs.length-2,2); //need to convert pages to spreads } for (i=0; i0) { ItemDetail(xy[minx][0].substr(4,10),xy[minx][0].substr(14,10),"","1","","","","FLYER",""); // item, karat", colour,qty,sz,desc,price,tab,row) } }