

ImageStruct = new Object();
ImageStruct["default"] = "\r\n\t\t\t<div id=\"picture\">\r\n\t\t\t\t<div id=\"mainImageOutline\" style=\"width: 250px; height: 0px;\" onclick=\"javascript:window.open(\'/_largeimage.cfm?image=\',\'popup\',\'width=600,height=600, scrollbars=yes\');\">\r\n\t\t\t\t\t<a href=\"javascript:void(0);\">\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t<img src=\"/images/product/images/noImageLarge.jpg\" alt=\"Image not available\" class=\"imgBorder\"/>\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t</a>\r\n\t\t\t\t\t<br />\r\n\t\t\t\t\t<a href=\"javascript:void(0);\"><img id=\"mainImage\" src=\"/images/retail/zoom.gif\" alt=\"Zoom\" /></a>\r\n\t\t\t\t</div>\r\n\t\t\t\t\r\n\t\t\t</div>\t\t\r\n\t\t\t<div id=\"previews\" style=\"padding-top:270px;\">\r\n\t\t\t\r\n\t\t\t</div>\r\n\t\t\t";


fldValueStruct = new Object();
fldValueStruct["fld1array"] =  new Array();
fldValueStruct["fld1array"][0] = new Object();
fldValueStruct["fld1array"][0]["value"] = 1637;
fldValueStruct["fld1array"][0]["text"] = "8.00 X 5.00 X 10.00";
fldValueStruct["fld1array"][1] = new Object();
fldValueStruct["fld1array"][1]["value"] = 1633;
fldValueStruct["fld1array"][1]["text"] = "10.00 X 10.00 X 10.00";
fldValueStruct["fld1array"][2] = new Object();
fldValueStruct["fld1array"][2]["value"] = 488;
fldValueStruct["fld1array"][2]["text"] = "13.00 X 5.00 X 13.00";
fldValueStruct["fld1array"][3] = new Object();
fldValueStruct["fld1array"][3]["value"] = 1634;
fldValueStruct["fld1array"][3]["text"] = "13.00 X 10.00 X 15.00";
fldValueStruct["fld1array"][4] = new Object();
fldValueStruct["fld1array"][4]["value"] = 1642;
fldValueStruct["fld1array"][4]["text"] = "13.00 X 7.00 X 14.00";
fldValueStruct["fld1array"][5] = new Object();
fldValueStruct["fld1array"][5]["value"] = 1644;
fldValueStruct["fld1array"][5]["text"] = "15.00 X 0.00 X 16.00";
fldValueStruct["fld1array"][6] = new Object();
fldValueStruct["fld1array"][6]["value"] = 1638;
fldValueStruct["fld1array"][6]["text"] = "16.00 X 6.00 X 13.00";
fldValueStruct["fld1array"][7] = new Object();
fldValueStruct["fld1array"][7]["value"] = 1046;
fldValueStruct["fld1array"][7]["text"] = "20.00 X 6.00 X 16.00";
fldValueStruct["fld2array"] =  new Array();
fldValueStruct["fld2array"][0] = new Object();
fldValueStruct["fld2array"][0]["value"] = 1506;
fldValueStruct["fld2array"][0]["text"] = "BLACK";
fldValueStruct["fld2array"][1] = new Object();
fldValueStruct["fld2array"][1]["value"] = 1447;
fldValueStruct["fld2array"][1]["text"] = "BURGUNDY";
fldValueStruct["fld2array"][2] = new Object();
fldValueStruct["fld2array"][2]["value"] = 1361;
fldValueStruct["fld2array"][2]["text"] = "CHOCOLATE";
fldValueStruct["fld2array"][3] = new Object();
fldValueStruct["fld2array"][3]["value"] = 377;
fldValueStruct["fld2array"][3]["text"] = "HOT PINK";
fldValueStruct["fld2array"][4] = new Object();
fldValueStruct["fld2array"][4]["value"] = 235;
fldValueStruct["fld2array"][4]["text"] = "HUNTER GREEN";
fldValueStruct["fld2array"][5] = new Object();
fldValueStruct["fld2array"][5]["value"] = 1562;
fldValueStruct["fld2array"][5]["text"] = "KHAKI";
fldValueStruct["fld2array"][6] = new Object();
fldValueStruct["fld2array"][6]["value"] = 304;
fldValueStruct["fld2array"][6]["text"] = "LIGHT PINK";
fldValueStruct["fld2array"][7] = new Object();
fldValueStruct["fld2array"][7]["value"] = 1655;
fldValueStruct["fld2array"][7]["text"] = "LIGHT PINK";
fldValueStruct["fld2array"][8] = new Object();
fldValueStruct["fld2array"][8]["value"] = 1640;
fldValueStruct["fld2array"][8]["text"] = "LIME";
fldValueStruct["fld2array"][9] = new Object();
fldValueStruct["fld2array"][9]["value"] = 1430;
fldValueStruct["fld2array"][9]["text"] = "NAVY";
fldValueStruct["fld2array"][10] = new Object();
fldValueStruct["fld2array"][10]["value"] = 215;
fldValueStruct["fld2array"][10]["text"] = "ORANGE";
fldValueStruct["fld2array"][11] = new Object();
fldValueStruct["fld2array"][11]["value"] = 1641;
fldValueStruct["fld2array"][11]["text"] = "POWDER BLUE";
fldValueStruct["fld2array"][12] = new Object();
fldValueStruct["fld2array"][12]["value"] = 1643;
fldValueStruct["fld2array"][12]["text"] = "POWDER BLUE";
fldValueStruct["fld2array"][13] = new Object();
fldValueStruct["fld2array"][13]["value"] = 1512;
fldValueStruct["fld2array"][13]["text"] = "RED";
fldValueStruct["fld2array"][14] = new Object();
fldValueStruct["fld2array"][14]["value"] = 1651;
fldValueStruct["fld2array"][14]["text"] = "red";
fldValueStruct["fld2array"][15] = new Object();
fldValueStruct["fld2array"][15]["value"] = 307;
fldValueStruct["fld2array"][15]["text"] = "ROYAL BLUE";
fldValueStruct["fld2array"][16] = new Object();
fldValueStruct["fld2array"][16]["value"] = 141;
fldValueStruct["fld2array"][16]["text"] = "WHITE";
fldValueStruct["fld2array"][17] = new Object();
fldValueStruct["fld2array"][17]["value"] = 248;
fldValueStruct["fld2array"][17]["text"] = "YELLOW";


AvailableProducts = new Object();
AvailableProducts["248_1638"] = 16005;
AvailableProducts["1430_1637"] = 16034;
AvailableProducts["1633_1641"] = 15925;
AvailableProducts["1512_1642"] = 15967;
AvailableProducts["1644_215"] = 16113;
AvailableProducts["1640_1644"] = 15976;
AvailableProducts["1644_1361"] = 15972;
AvailableProducts["1633_1640"] = 15924;
AvailableProducts["1447_1644"] = 15971;
AvailableProducts["1430_1638"] = 16002;
AvailableProducts["215_1637"] = 16121;
AvailableProducts["1641_1634"] = 15941;
AvailableProducts["1430_1634"] = 15942;
AvailableProducts["1638_1512"] = 16003;
AvailableProducts["304_488"] = 16108;
AvailableProducts["215_1634"] = 16107;
AvailableProducts["304_1642"] = 16110;
AvailableProducts["488_304"] = 16108;
AvailableProducts["141_1633"] = 15928;
AvailableProducts["1640_488"] = 15952;
AvailableProducts["1642_1447"] = 15959;
AvailableProducts["304_1633"] = 16104;
AvailableProducts["1447_1638"] = 15995;
AvailableProducts["1512_1644"] = 15979;
AvailableProducts["1638_1562"] = 15999;
AvailableProducts["1644_1506"] = 15970;
AvailableProducts["215_1644"] = 16113;
AvailableProducts["1046_1640"] = 16012;
AvailableProducts["1638_1447"] = 15995;
AvailableProducts["488_1506"] = 15946;
AvailableProducts["1638_1361"] = 15996;
AvailableProducts["1562_1642"] = 15963;
AvailableProducts["1633_248"] = 15929;
AvailableProducts["488_1641"] = 15953;
AvailableProducts["488_1562"] = 15951;
AvailableProducts["235_1634"] = 15937;
AvailableProducts["1506_1634"] = 15934;
AvailableProducts["1512_1046"] = 16015;
AvailableProducts["1644_1430"] = 15978;
AvailableProducts["1512_1633"] = 15927;
AvailableProducts["1562_1633"] = 15923;
AvailableProducts["1506_1046"] = 16006;
AvailableProducts["235_1642"] = 15961;
AvailableProducts["1637_248"] = 16037;
AvailableProducts["1637_235"] = 16029;
AvailableProducts["1637_304"] = 16120;
AvailableProducts["1633_215"] = 16105;
AvailableProducts["1634_1641"] = 15941;
AvailableProducts["1637_377"] = 16030;
AvailableProducts["1634_1447"] = 15935;
AvailableProducts["1633_1562"] = 15923;
AvailableProducts["1447_1633"] = 15919;
AvailableProducts["1046_377"] = 16010;
AvailableProducts["1046_141"] = 16016;
AvailableProducts["1046_1506"] = 16006;
AvailableProducts["1046_235"] = 16009;
AvailableProducts["1562_488"] = 15951;
AvailableProducts["1046_215"] = 16119;
AvailableProducts["1361_1634"] = 15936;
AvailableProducts["377_1642"] = 15962;
AvailableProducts["1562_1046"] = 16011;
AvailableProducts["1644_1512"] = 15979;
AvailableProducts["1637_1640"] = 16032;
AvailableProducts["1634_1506"] = 15934;
AvailableProducts["248_1634"] = 15945;
AvailableProducts["1644_377"] = 15974;
AvailableProducts["1644_1641"] = 15977;
AvailableProducts["1634_1562"] = 15939;
AvailableProducts["377_1638"] = 15998;
AvailableProducts["235_1638"] = 15997;
AvailableProducts["1642_1641"] = 15965;
AvailableProducts["377_1637"] = 16030;
AvailableProducts["248_1642"] = 15969;
AvailableProducts["215_1642"] = 16111;
AvailableProducts["1644_1640"] = 15976;
AvailableProducts["488_141"] = 15956;
AvailableProducts["1644_141"] = 15980;
AvailableProducts["304_1634"] = 16106;
AvailableProducts["141_1637"] = 16036;
AvailableProducts["1361_1642"] = 15960;
AvailableProducts["307_1637"] = 16204;
AvailableProducts["1638_304"] = 16116;
AvailableProducts["488_307"] = 16198;
AvailableProducts["1637_1562"] = 16031;
AvailableProducts["1634_307"] = 16197;
AvailableProducts["1644_235"] = 15973;
AvailableProducts["1430_1633"] = 15926;
AvailableProducts["1642_141"] = 15968;
AvailableProducts["1506_1642"] = 15958;
AvailableProducts["1512_488"] = 15955;
AvailableProducts["1637_1512"] = 16035;
AvailableProducts["488_215"] = 16109;
AvailableProducts["1634_1430"] = 15942;
AvailableProducts["1046_307"] = 16203;
AvailableProducts["1641_1637"] = 16033;
AvailableProducts["1642_1430"] = 15966;
AvailableProducts["1046_1562"] = 16011;
AvailableProducts["1638_235"] = 15997;
AvailableProducts["1562_1644"] = 15975;
AvailableProducts["1640_1642"] = 15964;
AvailableProducts["1633_1447"] = 15919;
AvailableProducts["1642_1562"] = 15963;
AvailableProducts["1644_1562"] = 15975;
AvailableProducts["1640_1633"] = 15924;
AvailableProducts["1638_377"] = 15998;
AvailableProducts["1638_215"] = 16117;
AvailableProducts["141_1638"] = 16004;
AvailableProducts["1640_1046"] = 16012;
AvailableProducts["1046_1430"] = 16014;
AvailableProducts["377_488"] = 15950;
AvailableProducts["307_1644"] = 16200;
AvailableProducts["1046_304"] = 16118;
AvailableProducts["1447_488"] = 15947;
AvailableProducts["215_488"] = 16109;
AvailableProducts["1642_307"] = 16199;
AvailableProducts["1430_1046"] = 16014;
AvailableProducts["248_1637"] = 16037;
AvailableProducts["1512_1638"] = 16003;
AvailableProducts["307_1638"] = 16202;
AvailableProducts["1637_1506"] = 16026;
AvailableProducts["307_1634"] = 16197;
AvailableProducts["141_488"] = 15956;
AvailableProducts["1634_235"] = 15937;
AvailableProducts["248_488"] = 15957;
AvailableProducts["1506_488"] = 15946;
AvailableProducts["304_1644"] = 16112;
AvailableProducts["248_1644"] = 15981;
AvailableProducts["1633_1361"] = 15920;
AvailableProducts["1638_1640"] = 16000;
AvailableProducts["1634_141"] = 15944;
AvailableProducts["307_488"] = 16198;
AvailableProducts["377_1633"] = 15922;
AvailableProducts["1361_1637"] = 16028;
AvailableProducts["1361_1633"] = 15920;
AvailableProducts["1641_1638"] = 16001;
AvailableProducts["1506_1633"] = 15918;
AvailableProducts["1430_1642"] = 15966;
AvailableProducts["488_1447"] = 15947;
AvailableProducts["1638_141"] = 16004;
AvailableProducts["1562_1637"] = 16031;
AvailableProducts["235_1633"] = 15921;
AvailableProducts["1637_1430"] = 16034;
AvailableProducts["1361_1638"] = 15996;
AvailableProducts["1506_1638"] = 15994;
AvailableProducts["307_1046"] = 16203;
AvailableProducts["1638_248"] = 16005;
AvailableProducts["235_1644"] = 15973;
AvailableProducts["1361_1644"] = 15972;
AvailableProducts["1644_1447"] = 15971;
AvailableProducts["1642_1512"] = 15967;
AvailableProducts["235_1046"] = 16009;
AvailableProducts["1642_304"] = 16110;
AvailableProducts["1046_1447"] = 16007;
AvailableProducts["1637_307"] = 16204;
AvailableProducts["1634_1361"] = 15936;
AvailableProducts["307_1642"] = 16199;
AvailableProducts["1640_1634"] = 15940;
AvailableProducts["141_1642"] = 15968;
AvailableProducts["1633_141"] = 15928;
AvailableProducts["1634_377"] = 15938;
AvailableProducts["1637_1361"] = 16028;
AvailableProducts["1634_215"] = 16107;
AvailableProducts["1638_1430"] = 16002;
AvailableProducts["1640_1637"] = 16032;
AvailableProducts["1642_1640"] = 15964;
AvailableProducts["1512_1637"] = 16035;
AvailableProducts["1633_307"] = 16196;
AvailableProducts["1634_1640"] = 15940;
AvailableProducts["1447_1634"] = 15935;
AvailableProducts["1633_1430"] = 15926;
AvailableProducts["1562_1638"] = 15999;
AvailableProducts["215_1633"] = 16105;
AvailableProducts["141_1644"] = 15980;
AvailableProducts["1642_248"] = 15969;
AvailableProducts["1642_1361"] = 15960;
AvailableProducts["1638_307"] = 16202;
AvailableProducts["488_235"] = 15949;
AvailableProducts["1633_304"] = 16104;
AvailableProducts["1638_1506"] = 15994;
AvailableProducts["488_1430"] = 15954;
AvailableProducts["215_1046"] = 16119;
AvailableProducts["488_1512"] = 15955;
AvailableProducts["488_1361"] = 15948;
AvailableProducts["235_1637"] = 16029;
AvailableProducts["488_1640"] = 15952;
AvailableProducts["377_1634"] = 15938;
AvailableProducts["304_1637"] = 16120;
AvailableProducts["141_1046"] = 16016;
AvailableProducts["1506_1644"] = 15970;
AvailableProducts["141_1634"] = 15944;
AvailableProducts["304_1046"] = 16118;
AvailableProducts["1644_248"] = 15981;
AvailableProducts["248_1633"] = 15929;
AvailableProducts["304_1638"] = 16116;
AvailableProducts["248_1046"] = 16017;
AvailableProducts["1046_1641"] = 16013;
AvailableProducts["1447_1046"] = 16007;
AvailableProducts["1361_488"] = 15948;
AvailableProducts["1641_1644"] = 15977;
AvailableProducts["1633_1506"] = 15918;
AvailableProducts["1641_1633"] = 15925;
AvailableProducts["1644_304"] = 16112;
AvailableProducts["1637_1447"] = 16027;
AvailableProducts["1506_1637"] = 16026;
AvailableProducts["307_1633"] = 16196;
AvailableProducts["1430_488"] = 15954;
AvailableProducts["1430_1644"] = 15978;
AvailableProducts["1642_1506"] = 15958;
AvailableProducts["1640_1638"] = 16000;
AvailableProducts["377_1644"] = 15974;
AvailableProducts["1638_1641"] = 16001;
AvailableProducts["1512_1634"] = 15943;
AvailableProducts["1633_377"] = 15922;
AvailableProducts["1637_141"] = 16036;
AvailableProducts["1637_215"] = 16121;
AvailableProducts["215_1638"] = 16117;
AvailableProducts["488_377"] = 15950;
AvailableProducts["1633_1512"] = 15927;
AvailableProducts["1633_235"] = 15921;
AvailableProducts["1634_304"] = 16106;
AvailableProducts["1644_307"] = 16200;
AvailableProducts["1447_1642"] = 15959;
AvailableProducts["1641_488"] = 15953;
AvailableProducts["377_1046"] = 16010;
AvailableProducts["1361_1046"] = 16008;
AvailableProducts["1642_215"] = 16111;
AvailableProducts["235_488"] = 15949;
AvailableProducts["1562_1634"] = 15939;
AvailableProducts["1634_248"] = 15945;
AvailableProducts["1634_1512"] = 15943;
AvailableProducts["488_248"] = 15957;
AvailableProducts["1641_1642"] = 15965;
AvailableProducts["1637_1641"] = 16033;
AvailableProducts["1447_1637"] = 16027;
AvailableProducts["1642_377"] = 15962;
AvailableProducts["1046_248"] = 16017;
AvailableProducts["1046_1361"] = 16008;
AvailableProducts["1641_1046"] = 16013;
AvailableProducts["1046_1512"] = 16015;
AvailableProducts["1642_235"] = 15961;


AttributeArray = new Object();
AttributeArray["1430"] = new Object();
AttributeArray["1430"]["value"] = 1430;
AttributeArray["1430"]["text"] = "NAVY";
AttributeArray["1430"]["prod_id"] = "15954,16014,15926,15942,16034,16002,15966,15978";
AttributeArray["1430"]["allowed"] = "488,1046,1633,1634,1637,1638,1642,1644";
AttributeArray["1651"] = new Object();
AttributeArray["1651"]["value"] = 1651;
AttributeArray["1651"]["text"] = "red";
AttributeArray["1638"] = new Object();
AttributeArray["1638"]["value"] = 1638;
AttributeArray["1638"]["text"] = "16.00 X 6.00 X 13.00";
AttributeArray["1638"]["prod_id"] = "16004,16117,15997,16005,16116,16202,15998,15996,16002,15995,15994,16003,15999,16000,16001";
AttributeArray["1638"]["allowed"] = "141,215,235,248,304,307,377,1361,1430,1447,1506,1512,1562,1640,1641";
AttributeArray["215"] = new Object();
AttributeArray["215"]["value"] = 215;
AttributeArray["215"]["text"] = "ORANGE";
AttributeArray["215"]["prod_id"] = "16109,16119,16105,16107,16121,16117,16111,16113";
AttributeArray["215"]["allowed"] = "488,1046,1633,1634,1637,1638,1642,1644";
AttributeArray["141"] = new Object();
AttributeArray["141"]["value"] = 141;
AttributeArray["141"]["text"] = "WHITE";
AttributeArray["141"]["prod_id"] = "15956,16016,15928,15944,16036,16004,15968,15980";
AttributeArray["141"]["allowed"] = "488,1046,1633,1634,1637,1638,1642,1644";
AttributeArray["1512"] = new Object();
AttributeArray["1512"]["value"] = 1512;
AttributeArray["1512"]["text"] = "RED";
AttributeArray["1512"]["prod_id"] = "15955,16015,15927,15943,16035,16003,15967,15979";
AttributeArray["1512"]["allowed"] = "488,1046,1633,1634,1637,1638,1642,1644";
AttributeArray["488"] = new Object();
AttributeArray["488"]["value"] = 488;
AttributeArray["488"]["text"] = "13.00 X 5.00 X 13.00";
AttributeArray["488"]["prod_id"] = "15956,16109,15949,15957,16108,16198,15950,15948,15954,15947,15946,15955,15951,15952,15953";
AttributeArray["488"]["allowed"] = "141,215,235,248,304,307,377,1361,1430,1447,1506,1512,1562,1640,1641";
AttributeArray["1562"] = new Object();
AttributeArray["1562"]["value"] = 1562;
AttributeArray["1562"]["text"] = "KHAKI";
AttributeArray["1562"]["prod_id"] = "15951,16011,15923,15939,16031,15999,15963,15975";
AttributeArray["1562"]["allowed"] = "488,1046,1633,1634,1637,1638,1642,1644";
AttributeArray["1506"] = new Object();
AttributeArray["1506"]["value"] = 1506;
AttributeArray["1506"]["text"] = "BLACK";
AttributeArray["1506"]["prod_id"] = "15946,16006,15918,15934,16026,15994,15958,15970";
AttributeArray["1506"]["allowed"] = "488,1046,1633,1634,1637,1638,1642,1644";
AttributeArray["1641"] = new Object();
AttributeArray["1641"]["value"] = 1641;
AttributeArray["1641"]["text"] = "POWDER BLUE";
AttributeArray["1641"]["prod_id"] = "15953,16013,15925,15941,16033,16001,15965,15977";
AttributeArray["1641"]["allowed"] = "488,1046,1633,1634,1637,1638,1642,1644";
AttributeArray["1637"] = new Object();
AttributeArray["1637"]["value"] = 1637;
AttributeArray["1637"]["text"] = "8.00 X 5.00 X 10.00";
AttributeArray["1637"]["prod_id"] = "16036,16121,16029,16037,16120,16204,16030,16028,16034,16027,16026,16035,16031,16032,16033";
AttributeArray["1637"]["allowed"] = "141,215,235,248,304,307,377,1361,1430,1447,1506,1512,1562,1640,1641";
AttributeArray["1634"] = new Object();
AttributeArray["1634"]["value"] = 1634;
AttributeArray["1634"]["text"] = "13.00 X 10.00 X 15.00";
AttributeArray["1634"]["prod_id"] = "15944,16107,15937,15945,16106,16197,15938,15936,15942,15935,15934,15943,15939,15940,15941";
AttributeArray["1634"]["allowed"] = "141,215,235,248,304,307,377,1361,1430,1447,1506,1512,1562,1640,1641";
AttributeArray["1633"] = new Object();
AttributeArray["1633"]["value"] = 1633;
AttributeArray["1633"]["text"] = "10.00 X 10.00 X 10.00";
AttributeArray["1633"]["prod_id"] = "15928,16105,15921,15929,16104,16196,15922,15920,15926,15919,15918,15927,15923,15924,15925";
AttributeArray["1633"]["allowed"] = "141,215,235,248,304,307,377,1361,1430,1447,1506,1512,1562,1640,1641";
AttributeArray["1642"] = new Object();
AttributeArray["1642"]["value"] = 1642;
AttributeArray["1642"]["text"] = "13.00 X 7.00 X 14.00";
AttributeArray["1642"]["prod_id"] = "15968,16111,15961,15969,16110,16199,15962,15960,15966,15959,15958,15967,15963,15964,15965";
AttributeArray["1642"]["allowed"] = "141,215,235,248,304,307,377,1361,1430,1447,1506,1512,1562,1640,1641";
AttributeArray["1447"] = new Object();
AttributeArray["1447"]["value"] = 1447;
AttributeArray["1447"]["text"] = "BURGUNDY";
AttributeArray["1447"]["prod_id"] = "15947,16007,15919,15935,16027,15995,15959,15971";
AttributeArray["1447"]["allowed"] = "488,1046,1633,1634,1637,1638,1642,1644";
AttributeArray["1640"] = new Object();
AttributeArray["1640"]["value"] = 1640;
AttributeArray["1640"]["text"] = "LIME";
AttributeArray["1640"]["prod_id"] = "15952,16012,15924,15940,16032,16000,15964,15976";
AttributeArray["1640"]["allowed"] = "488,1046,1633,1634,1637,1638,1642,1644";
AttributeArray["304"] = new Object();
AttributeArray["304"]["value"] = 304;
AttributeArray["304"]["text"] = "LIGHT PINK";
AttributeArray["304"]["prod_id"] = "16108,16118,16104,16106,16120,16116,16110,16112";
AttributeArray["304"]["allowed"] = "488,1046,1633,1634,1637,1638,1642,1644";
AttributeArray["377"] = new Object();
AttributeArray["377"]["value"] = 377;
AttributeArray["377"]["text"] = "HOT PINK";
AttributeArray["377"]["prod_id"] = "15950,16010,15922,15938,16030,15998,15962,15974";
AttributeArray["377"]["allowed"] = "488,1046,1633,1634,1637,1638,1642,1644";
AttributeArray["1643"] = new Object();
AttributeArray["1643"]["value"] = 1643;
AttributeArray["1643"]["text"] = "POWDER BLUE";
AttributeArray["1644"] = new Object();
AttributeArray["1644"]["value"] = 1644;
AttributeArray["1644"]["text"] = "15.00 X 0.00 X 16.00";
AttributeArray["1644"]["prod_id"] = "15980,16113,15973,15981,16112,16200,15974,15972,15978,15971,15970,15979,15975,15976,15977";
AttributeArray["1644"]["allowed"] = "141,215,235,248,304,307,377,1361,1430,1447,1506,1512,1562,1640,1641";
AttributeArray["235"] = new Object();
AttributeArray["235"]["value"] = 235;
AttributeArray["235"]["text"] = "HUNTER GREEN";
AttributeArray["235"]["prod_id"] = "15949,16009,15921,15937,16029,15997,15961,15973";
AttributeArray["235"]["allowed"] = "488,1046,1633,1634,1637,1638,1642,1644";
AttributeArray["1655"] = new Object();
AttributeArray["1655"]["value"] = 1655;
AttributeArray["1655"]["text"] = "LIGHT PINK";
AttributeArray["248"] = new Object();
AttributeArray["248"]["value"] = 248;
AttributeArray["248"]["text"] = "YELLOW";
AttributeArray["248"]["prod_id"] = "15957,16017,15929,15945,16037,16005,15969,15981";
AttributeArray["248"]["allowed"] = "488,1046,1633,1634,1637,1638,1642,1644";
AttributeArray["307"] = new Object();
AttributeArray["307"]["value"] = 307;
AttributeArray["307"]["text"] = "ROYAL BLUE";
AttributeArray["307"]["prod_id"] = "16198,16203,16196,16197,16204,16202,16199,16200";
AttributeArray["307"]["allowed"] = "488,1046,1633,1634,1637,1638,1642,1644";
AttributeArray["1046"] = new Object();
AttributeArray["1046"]["value"] = 1046;
AttributeArray["1046"]["text"] = "20.00 X 6.00 X 16.00";
AttributeArray["1046"]["prod_id"] = "16016,16119,16009,16017,16118,16203,16010,16008,16014,16007,16006,16015,16011,16012,16013";
AttributeArray["1046"]["allowed"] = "141,215,235,248,304,307,377,1361,1430,1447,1506,1512,1562,1640,1641";
AttributeArray["1361"] = new Object();
AttributeArray["1361"]["value"] = 1361;
AttributeArray["1361"]["text"] = "CHOCOLATE";
AttributeArray["1361"]["prod_id"] = "15948,16008,15920,15936,16028,15996,15960,15972";
AttributeArray["1361"]["allowed"] = "488,1046,1633,1634,1637,1638,1642,1644";


function filterAttribute(attrID,fldID,srcFld){
	var fld = document.getElementById('attributeID_'+fldID);
	attrID = srcFld.options[srcFld.selectedIndex].value;
	var valueCount = 1;
	var noValueCount = 0;
	if (attrID > 0) {
		var allowedValueList = AttributeArray[attrID]['allowed'];
		var prod_id = AttributeArray[attrID]['prod_id'];
		var allowedValueArray = allowedValueList.split(',');
		var notAllowedValueArray = new Array();
		//alert(attrID);
		//alert(allowedValueList);
	
		//alert(fld.selectedIndex)
		
		var selectedValue = '';
		var removed = false;
		if (fld.selectedIndex > 0){
			selectedValue = fld.options[fld.selectedIndex].value;
		}
		if (fld.options.length > 1) {
			removed = true;
			for(var i=fld.options.length-1;i>=1;i--){
				fld.remove(i);
			}
			
			//fldArray = eval('fld'+fldID+'Array');
			fldArray = fldValueStruct['fld'+fldID+'array']
			for(var i=0; i< fldArray.length; i++){
		
				var  currentValue = fldArray[i]['value'];
			
				for (var j = 0; j < allowedValueArray.length; j++){
					var allowedValue = allowedValueArray[j];
					//alert(currentValue+ ' - ' + allowedValue)
					if (currentValue == allowedValue || attrID == 0){
						fld.options[valueCount] = new Option(fldArray[i]['text'], fldArray[i]['value'], false, false);
						if (selectedValue == currentValue)
							fld.options[valueCount].selected = true;
							
						valueCount = valueCount + 1;
					}
					else {
						
						notAllowedValueArray[noValueCount] = currentValue;
						noValueCount = noValueCount + 1;
					}
		
				}
			}
		}
		
		for(var i=0; i< notAllowedValueArray.length; i++){
			var divID = document.getElementById('img'+notAllowedValueArray[i])
			if (divID!= null) { 
				divID.innerHTML = '<img src="/images/retail/inActive.png">';
			}
		}
		
		for(var i=0; i< allowedValueArray.length; i++){
			var divID = document.getElementById('img'+allowedValueArray[i])
			if (divID!= null) { 
				divID.innerHTML = '';
			}
		}
	}
	else {
		var selectedValue = '';
		var removed = false;
		if (fld.selectedIndex > 0){
			selectedValue = fld.options[fld.selectedIndex].value;
		}
		
		if (fld.options.length > 1) {
			removed = true;
			for(var i=fld.options.length-1;i>=1;i--){
				fld.remove(i);
			}
					
			fldArray = fldValueStruct['fld'+fldID+'array']
			//alert(fldArray.length);
			for(var i=0; i< fldArray.length; i++){
				fld.options[i+1] = new Option(fldArray[i]['text'], fldArray[i]['value'], false, false);
				if (selectedValue == currentValue)
					fld.options[i+1].selected = true;
					
				var divID = document.getElementById('img'+fldArray[i]['value']);
				if (divID!= null) { 
					divID.innerHTML = '';
				}
				
			}
		}
	}
	
	if (!removed || (fld.selectedIndex > 0 && srcFld.selectedIndex > 0 )){
		value = fld.options[fld.selectedIndex].value;
		attrID = srcFld.options[srcFld.selectedIndex].value;
		key = value+'_'+attrID;
		//alert(key);
		//alert(AvailableProducts[key]);
		getProductPrice('/index.cfm?event=shop.dspProductPrice&prod_id='+AvailableProducts[key]);
	}
	else {
		if (fld.selectedIndex == 0 && srcFld.selectedIndex == 0 )
			Spry.Utils.setInnerHTML('imageText',ImageStruct['default']);

		Spry.Utils.setInnerHTML('productPrice', '');
	}
	//alert(fldArray)
	//alert('fld'+fldID+'Array');

	//fld.options[boxLength] = new Option(Text, Value, false, false);
	
	/*for (var j = 0; j < fld.length; j++) {
		if (fld.options[j].value == attrID){
			
		}
	}
	alert(AttributeArray[attrID]['allowed']);*/
}
function selectColor(id,imgText,imgBorder){
	//alert(id);
	var imgTagText = document.getElementById(imgText).innerHTML;
	var imgBorderDiv = document.getElementById(imgBorder);
	
	if (imgTagText.indexOf('<img') >=0 )
		alert('Not available');
	else {
		//alert(imgBorderDiv.style.border);
		//imgBorderDiv.style.border = '5px'
		var fld = document.getElementById('attributeID_2');
		for(i=fld.options.length-1;i>=1;i--){
		if (fld.options[i].value == id)
			fld.options[i].selected = true;
		}
	
		filterAttribute(id,1,fld);
	}
}

	function doAdd(){
		Spry.Utils.setInnerHTML('updateResponseDiv', 'Processing.....');
		return Spry.Utils.submitForm(document.forms['frmProductDetail'], updateResponseDiv);
	}

	function doCheckStatus(sc_que_id){
		document.forms['frmCartStatus'].sc_que_id.value = sc_que_id;
		return Spry.Utils.submitForm(document.forms['frmCartStatus'], updateResponseDiv);
	}
	function updateResponseDivTest(req){
		Spry.Utils.setInnerHTML('updateResponseDiv', req.xhRequest.responseText);
	}
	
	function updateResponseDiv(req){

		var responseXML = Spry.XML.documentToObject(req.xhRequest.responseXML);
		if (responseXML.ShopCart) {
			var sc_que_id = responseXML.ShopCart['sc_que_id']._value();
			var sc_que_status_id = responseXML.ShopCart['sc_que_status_id']._value();
			var sc_que_message = responseXML.ShopCart['sc_que_message']._value();
		}
		if (sc_que_status_id == 3) { // Product added to shopping cart
			
			sc_que_message = '<h3>'+sc_que_message + '</h3>&nbsp;&nbsp;&nbsp;&nbsp;<a href="/index.cfm?event=cart.dspView"><img src="/images/retail/cart.gif" />&nbsp;View Cart</a>';
			
			var sc_sub_total = responseXML.ShopCart['sc_sub_total']._value();

			if (document.getElementById('cartTotal') != null)
				Spry.Utils.setInnerHTML('cartTotal', '$'+sc_sub_total);

			Spry.Utils.setInnerHTML('updateResponseDiv', sc_que_message);
		}
		else if (sc_que_status_id == 1) // In Que
			doCheckStatus(sc_que_id);
		else if (sc_que_status_id == 5 ) {// Unable to add to shopping cart
			sc_que_message = '<h3> out of stock </h3>';
			Spry.Utils.setInnerHTML('updateResponseDiv', sc_que_message);
		}
	}
	
	function getProductPrice(url){
		Spry.Utils.setInnerHTML('productPrice', 'Loading...');
		Spry.Utils.setInnerHTML('updateResponseDiv', '');
		var req = Spry.Utils.loadURL("GET", url, true, processDispPriceResult);
	}
	
	function processDispPriceResult(req){
		var responseXML = Spry.XML.documentToObject(req.xhRequest.responseXML);
		
		var priceText = responseXML.product['price']._value();
		var imageText = responseXML.product['image']._value();
		//alert(responseXML);
		Spry.Utils.setInnerHTML('productPrice', priceText);
		Spry.Utils.setInnerHTML('imageText', imageText);
	}

	
	function fadeIt(ele,url){
		Spry.Utils.setInnerHTML(ele, 'Loading...');
		Spry.Utils.setInnerHTML('productPrice', '');
		Spry.Utils.setInnerHTML('updateResponseDiv', '');
		//FilterData();
		Spry.Utils.updateContent(ele,url);
	}
	
	var keyArray = new Array();
	
	
	//var fld1 = document.getElementById('attributeID_1');
	var attrFld1 = eval(document.forms['frmProductDetail'].attributeID_1);
	if (attrFld1.options.length == 2){
		attrFld1.options[0]= null;
		attrFld1.options[0].selected = true;
		
		keyArray[0] = attrFld1.options[attrFld1.selectedIndex].value;
	}
	
	else
		attrFld1.options[0].selected = true;
	
	//var fld2 = document.getElementById('attributeID_2');
	var attrFld2 = eval(document.forms['frmProductDetail'].attributeID_2);
	if (attrFld2.options.length == 2){
		attrFld2.options[0]= null;
		attrFld2.options[0].selected = true;
		
		keyArray[1] = attrFld2.options[attrFld2.selectedIndex].value;
	}
	
	else
		attrFld2.options[0].selected = true;
	
	
	//alert(keyArray.length);
	var key = '';
	for(var i=0; i < keyArray.length;i++){
		if (keyArray[i] != undefined){
			if (key.length ==0)
				key = keyArray[i];
			else
				key = key + '_' + keyArray[i];
		}
	}
	if (keyArray.length > 0 && key.indexOf('_') >0){
		getProductPrice('/index.cfm?event=shop.dspProductPrice&prod_id='+AvailableProducts[key]);
	}
	else {
		
	}
	

