//REPLACE L, G, K, Y, P, W, R, //change all function names function loadxy50() { //next line, omit var and it becomes a global array (use xy=[ not var xy=[ ) xy = [ ["",0,0] ,["5001ICG3064E0510KT PINK",109,232] ,["5001ICG3064P0210KT PINK",85,388] ,["5002ICG2927P0210KT WG",73,93] ,["5002G2770/P 10KT PINK",171,73] ,["5002JVJ3758 10KT WG",267,105] ,["5002JVJ3756 10KT W&PK",361,48] ,["5002ICG3110P0210KT YELL",352,255] ,["5002ICG3095P0210KT YELL",360,423] ,["5002G3085/E 10KT YELL",81,494] ,["5002JVJ3781 10KT YELL",93,585] ,["5002JVJ3760 10KT YELL",215,527] ,["5002ICJ3793/0210KT YELL",361,554] ,["5002G2994/P 10KT WG",499,91] ,["5002G2291/P 10KT W&PK",579,101] ,["5002ICG3112P0210KT W&Y",672,91] ,["5002ICG3057P0210KT W&PK",749,100] ,["5002ICG3072P0210KT W&PK",827,101] ,["5002ICG3117P0210KT YELL",532,263] ,["5002G3123/P 10KT YELL",541,417] ,["5002ICG3118B0210KT YELL",782,509] ,["5003ICJ3644/7018KT Y&W",81,96] ,["5003ICJ3606/5018KT WG",191,43] ,["5003ICJ3580/3014KT W&PK",360,85] ,["5003ICJ3732/7018KT PK&W",335,209] ,["5003ICJ3732/W 18KT PINK",373,272] ,["5003ICJ3236/0310KT WG",83,426] ,["5003ICJ3236/W 10KT WG",104,469] ,["5003ICJ3235/0310KT WG",233,361] ,["5003ICJ3235/W 10KT WG",226,412] ,["5003ICJ3248/0410KT WG",368,411] ,["5003ICJ3248/W 10KT WG",353,466] ,["5003ICJ3747/3014KT YELL",147,540] ,["5003ICJ3477/0914KT YELL",309,544] ,["5003JVJ3719 10KT WG",538,46] ,["5003JVJ3719 10KT PINK",538,84] ,["5003JVJ3719 10KT YELL",543,112] ,["5003JVJ3651/D 10KT PINK",540,227] ,["5003JVJ3552 10KT PINK",630,160] ,["5003JVJ3429 10KT PINK",698,88] ,["5003JVJ3188/W 14KT PINK",804,46] ,["5003JVJ3536 10KT YELL",786,209] ,["5003JVJ3536 10KT WG",772,241] ,["5003JVJ3536 10KT PINK",768,274] ,["5003JVJ3284 10KT PINK",764,348] ,["5003JVJ1599 10KT WG",780,411] ,["5003JVJ2194 10KT YELL",751,480] ,["5003JVJ3782 10KT WG",787,559] ,["5003G2852/E 10KT YELL",507,444] ,["5003ICG3114E0510KT W&PK",608,426] ,["5003G2860/E 10KT PINK",510,542] ,["5003G3059/E 10KT WG",598,570] ,["5004G2538/P 10KT W&PK",67,84] ,["5004ICG3116P0210KT W&Y",156,72] ,["5004G2732/E 10KT YELL",261,77] ,["5004ICG2924P0210KT YELL",363,84] ,["5004G3025P/PS 10KT PINK",86,237] ,["5004G3025E/PS 10KT PINK",166,229] ,["5004ICG3007E0510KT PINK",73,316] ,["5004ICJ3627/0210KT PINK",138,359] ,["5004ICG3007P0210KT PINK",208,312] ,["5004G3113/P 10KT PINK",357,259] ,["5004JVJ3725 10KT W&PK",351,415] ,["5004ICG2629P0210KT PK&W",73,552] ,["5004ICJ3427/0210KT PK&W",134,605] ,["5004ICG2931P0210KT PK&W",220,559] ,["5004ICG3093P0210KT W&PK",327,536] ,["5004G3061P/PS 10KT W&PK",391,599] ,["5004G2913P/RHG10KT WG",509,40] ,["5004G2913E/RHG10KT WG",572,57] ,["5004JVJ3688RHG10KT WG",525,104] ,["5004G2741P/BT SILVER",727,84] ,["5004JVJ3694PTZ10KT PINK",813,42] ,["5004JVJ3694/M10KT WG",814,84] ,["5004JVJ3694/CT10KT YELL",819,124] ,["5004ICG3115P0210KT W&PK",544,260] ,["5004G3122/P 10KT YELL",543,418] ,["5004ICG3084P0510KT W&Y",504,573] ,["5004ICG2692P0510KT WG",570,572] ,["5004ICG2891P0510KT YELL",629,572] ,["5004ICG2897P1410KT PINK",686,564] ,["5004ICG3034P0510KT W&PK",765,557] ,["5004ICG3082P0510KT W&PK",836,549] ,["5005FG102P-4 10KT W&Y",299,168] ,["5005FG103P-7 10KT WG",387,223] ,["5005MONET 10KT WG",103,360] ,["5005FG104P-7 10KT WG",224,335] ,["5005FJ101-5 10KT PINK",366,322] ,["5005FJ100-5 10KT WG",368,393] ,["5005FJ141-A 10KT YELL",87,447] ,["5005FJ141-C 10KT WG",169,427] ,["5005FJ131-8 10KT YELL",326,463] ]; } function xy50(book) { //xy77(7702) book is actually the spread //alert(book); var x,y; var zoom = document.documentElement.clientWidth / window.innerWidth; x=(mouse_x/zoom)-(document.getElementById("div620t1").offsetLeft/zoom)-(document.getElementById("flyer_sprd").offsetLeft/zoom); 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/(document.getElementById("flyer_spread").height)*675; y=y/zoom; loadxy50(); var minx; minx=0; 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) } }