//REPLACE L, G, K, Y, P, W, R, //change all function names function loadxy80() { //next line, omit var and it becomes a global array (use xy=[ not var xy=[ ) xy = [ ["",0,0] ,["8001ICG3578P0210KT YELL",327,233] ,["8001ICG3578E0410KT YELL",328,318] ,["8001ICJ4139/0210KT YELL",327,406] ,["8002G3562E/WH 10KT YELL",577,125] ,["8002G3562P/WH 10KT YELL",674,138] ,["8002G3571E/WH 10KT YELL",782,128] ,["8002G3530P/WH 10KT YELL",534,272] ,["8002G3530E/WH 10KT YELL",640,261] ,["8002JVJ4099/WH10KT YELL",771,275] ,["8002JVJ4071 10KT YELL",569,399] ,["8002JVJ3047 10KT WG",567,455] ,["8002JVJ4076 10KT YELL",562,515] ,["8002JVJ3194 10KT WG",563,572] ,["8002JVJ3196 10KT YELL",565,629] ,["8002ICG3496P0310KT YELL",693,440] ,["8002ICG3517P1410KT YELL",766,464] ,["8003G3535/P 10KT W&Y",98,346] ,["8003G3310/P 10KT YELL",191,314] ,["8003G3310/E 10KT YELL",287,313] ,["8003JVJ4131 10KT Y&W",165,517] ,["8003JVJ4081 10KT Y&W",255,460] ,["8003JVJ3957 10KT Y&W",339,511] ,["8003JVJ3967 10KT W&Y",250,577] ,["8003G3013E/WH 10KT YELL",530,97] ,["8003G3408P/WH 10KT YELL",658,93] ,["8003G3019/E 10KT YELL",810,93] ,["8003ICJ3961/0210KT YELL",557,381] ,["8003ICJ3962/0210KT YELL",560,447] ,["8003ICJ3965/0210KT YELL",558,506] ,["8003ICJ3963/0210KT YELL",561,577] ,["8003ICJ3964/0210KT YELL",560,644] ,["8003FIG3229EWH10KT YELL",755,386] ,["8003G3352/P 10KT YELL",711,580] ,["8003G3352/E 10KT YELL",800,562] ,["8004G3028P/AM 10KT YELL",158,67] ,["8004G2913P/PTZ10KT WG",235,64] ,["8004G3309P/R 10KT YELL",305,69] ,["8004JVJ3478/AM10KT YELL",94,236] ,["8004JVJ3688PTZ10KT WG",223,234] ,["8004JVJ3939/R 10KT YELL",373,231] ,["8004G3216P/RHG10KT YELL",70,496] ,["8004GEM879ERHG10KT WG",155,492] ,["8004JVJ3694RHG10KT WG",124,591] ,["8004JVJ4025RHG10KT YELL",123,625] ,["8004G2539P/PTZ10KT YELL",264,530] ,["8004G2741P/BT SILVER",398,519] ,["8004G3545/P 10KT Y&W",571,354] ,["8004G3531/P 10KT WG",572,445] ,["8004ICG2705P0210KT YELL",567,512] ,["8004G3491/P 10KT YELL",770,309] ,["8004JVJ4108 10KT YELL",771,371] ,["8004JVJ3746 10KT WG",770,428] ,["8004JVJ737 10KT YELL",766,507] ,["8005ICJ3732/7014KT Y&W",128,299] ,["8005ICJ3912/5014KT Y&W",277,295] ,["8005ICJ3994/7014KT Y&W",304,381] ,["8005ICJ3571/5014KT WG",167,491] ,["8005ICJ3644/7014KT Y&W",335,481] ,["8005ICJ3099/5014KT WG",252,564] ,["8005ICJ3236/0310KT WG",527,31] ,["8005ICJ3236/W 10KT WG",545,84] ,["8005ICJ3248/0410KT WG",667,73] ,["8005ICJ3248/W 10KT WG",663,134] ,["8005ICJ3235/0310KT WG",790,40] ,["8005ICJ3235/W 10KT WG",804,86] ,["8005ICJ3825/0510KT Y&W",793,146] ,["8005ICJ3825/W 10KT Y&W",789,203] ,["8005ICJ3785/2010KT YELL",550,437] ,["8005ICJ3956/3014KT W&Y",677,496] ,["8005ICJ3907/3014KT YELL",787,438] ,["8005ICJ4083/5014KT Y&W",558,549] ,["8005ICJ3663/3014KT W&Y",768,566] ,["8006ICG1160P1014KT WG",56,86] ,["8006ICG1148P1014KT WG",133,88] ,["8006ICG2719P1014KT WG",206,94] ,["8006ICG1159E1514KT WG",73,184] ,["8006ICG1147E1514KT WG",200,172] ,["8006ICG2719E1514KT WG",302,170] ,["8006ICJ3913/0910KT WG",114,416] ,["8006ICJ4100/0910KT YELL",112,485] ,["8006ICJ4135 10KT YELL",113,555] ,["8006ICG3534P0410KT YELL",240,483] ,["8006ICJ4036/0910KT YELL",359,421] ,["8006G3509/P 10KT YELL",582,358] ,["8006G3509/E 10KT YELL",662,357] ,["8006G3285/P 10KT YELL",762,314] ,["8006JVJ3917 10KT YELL",565,487] ,["8006JVJ4123 10KT YELL",649,542] ,["8006G3155/E 10KT YELL",762,505] ,["8006JVJ3300/1010KT WG",275,581] ,["8006JVJ3300/2514KT YELL",368,599] ,["8007G3492P/OP 10KT YELL",76,311] ,["8007G3492E/OP 10KT YELL",168,312] ,["8007JVJ4098/OP10KT YELL",126,378] ,["8007ICJ4079/OP10KT YELL",129,460] ,["8007G3563P/AM 10KT YELL",281,345] ,["8007ICG3567PMT10KT YELL",354,374] ,["8007G3373E/AM 10KT YELL",295,499] ,["8007G3373P/AM 10KT YELL",379,519] ,["8007JVJ3948/AM10KT YELL",325,578] ,["8007ICG3572E1010KT YELL",535,123] ,["8007ICG3572P0510KT YELL",625,106] ,["8007ICJ4136/0510KT YELL",578,192] ,["8007ICG3566PAQ10KT YELL",708,106] ,["8007ICG3566EAQ10KT YELL",800,105] ,["8007ICJ4132/AQ10KT YELL",756,188] ,["8007G3549E/E 10KT YELL",546,532] ,["8007G3549P/E 10KT YELL",648,535] ,["8007JVJ4093/E 10KT YELL",540,617] ,["8007ICJ4109/E 10KT YELL",708,599] ,["8008JVJ3533/G 10KT WG",97,53] ,["8008G2004 SIL/10Y",225,109] ,["8008WB449/G 10KT WG",361,44] ,["8008WB458 10KT W&Y",105,171] ,["8008JVJ3059 10KT W&Y",360,164] ,["8008JVJ2413/SLSIL/10Y",145,424] ,["8008JVJ404/SS 10KT WG",311,424] ,["8008JVJ3836PBKSILVER",91,565] ,["8008JVJ3875/OX10KT WG",228,599] ,["8008JVJ3182/OXSIL/10Y",367,568] ,["8008ICG3400P1410KT YELL",504,429] ,["8008ICG3372P1410KT YELL",575,422] ,["8008ICG3421P1110KT YELL",638,419] ,["8008ICG2891P0510KT YELL",707,428] ,["8008ICG3401P1410KT YELL",781,421] ,["8008ICG2692P0510KT WG",525,564] ,["8008ICG3579P0510KT YELL",603,558] ,["8008ICG2897P1410KT WG",690,566] ,["8009ICG3569PTZ10KT WG",329,126] ,["8009ICG3575PBT10KT YELL",296,253] ,["8009ICG3576PGA10KT YELL",373,294] ]; } //for mouseover on flyer for price function xyp80(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 (isMobileDevice) { alert("aaaa"); } 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 xy80(book) { var x,y; var zoom = document.documentElement.clientWidth / window.innerWidth; //alert(zoom); x=(mouse_x/zoom)-(document.getElementById("div621").offsetLeft/zoom); //alert(mouse_x+" | "+zoom+" | "+document.getElementById("div621").offsetLeft); //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; } } //alert(x); //alert(document.getElementById("div621").style.width); //874 844 //alert(x); //if (flyershown.substr(2,2)=="01") { x=x-parseInt(document.getElementById("div621").style.width)/2; } //alert(document.getElementById("flyer_ndx").width); //1 for mobile if (isMobileDevice) { x=x-parseInt(document.getElementById("div621").offsetLeft/zoom); //85 x=x/parseInt(document.getElementById("div621").style.width)*470; if (flyershown.substr(2,2)=="01") { x=x; }else{ if (isOdd(Number(flyershown.substr(2,2)))) { x=x+470; } } }else{ 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 } //alert(flyershown+" | "+fs); //alert(xy.length); 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) } } function xy80old(book) { //xy75(7502) book is actually the spread winsize(); var x,y; x=mouse_x-document.getElementById("div620t1").offsetLeft-document.getElementById("flyer_sprd").offsetLeft; x=x/document.getElementById("flyer_ndx").width*230; //ok to use flyer_ndx becuase that was how it was scaled y=((mouse_y-document.getElementById("div620").offsetTop)/winW*1280); //use winW*1280 instead of winH*752 because scaled by width var zoom = document.documentElement.clientWidth / window.innerWidth; y=y/zoom; loadxy75(); var minx; minx=0; for (i=0; i0) { ItemDetail(xy[minx][0].substr(4,10),xy[minx][0].substr(14,10),"1","","",""); //item,karat,canedit("Y" for yes) } }