var scRandConts= function ( ){var Y=[ ];
 this.addObj= function (id,name,img,price,saleprice){X(id,name,img,price,saleprice);
 } ;
 this.display= function (o0,O0,l0,i0){I0(o0,O0,Y,l0,i0);
 } ;
 function X(id,name,img,price,saleprice){var o1= {} ;
 o1.id=id.toLowerCase( );
 o1.name=name;
 o1.img=img;
 o1.price=price;
 o1.saleprice=saleprice;
 Y.push(o1);
 }function O1(l1){var i1="";
 if (l1.img!="-@N\x55LL@-"){i1+="\x3ca\x20href=\042"+l1.id+"\x2e\x68tml\042>\074img al\x74=\042"+l1.name+"\042 src\x3d\042"+l1.img+"\x22 />\x3c/a>";
 }return i1;
 }function I1(l1){var i1="\074div \x63lass\x3d\042\x6eam\x65\042\x3e\074a hr\x65f=\042"+l1.id+".html\042>"+l1.name+"\074/a\x3e\074\x2fd\x69v>";
 if (l1.price!="\x2d\x40NULL@\x2d"){i1+="\x3c\x64iv \x63\154\x61ss=\x22pric\x65"+((l1.saleprice=="-\x40N\x55\114\x4c@-")?"\x2db\x6f\154\x64": "")+"\042>"+l1.price+"\074/d\x69v>";
 }if (l1.saleprice!="\x2d\x40NULL\x40-"){i1+="\074div cla\x73s=\x22\163\x61le-p\x72ice-\x62old\042>"+l1.saleprice+"\074/div>";
 }return i1;
 }function I0(o0,O0,o2,l0,i0){var O2=document.getElementById(o0);
 if (O2 && (o2.length>0)){O2.innerHTML="";
 i0=i0.toString( ).toLowerCase( );
 var l2=(i0=="e\x6cl")? true : false;
 O0=(o2.length<O0)?o2.length:O0;
 l0=(l0>O0)?O0:l0;
 i2=Math.ceil(O0/l0);
 o2=I2(o2,O0);
 var i1="\074ta\x62le ce\x6clpad\x64ing=\0420\042 cell\x73paci\x6eg=\0420\x22 w\x69dt\x68=\04210\x30%\042 c\x6cass\x3d\042con\x74e\x6ets\x2dt\x61b\x6ce\042>";
 i1+= "<tr><td class=\"bestsellersheader\"><img src=\"/lib/yhst-99117540575822/bestsellers.gif\" alt=\"Bestsellers\"></td></tr>";
 for (var i=0;
 i<i2;
 i++){var o3=i*l0;
 O3=((o3+l0)>O0)?O0-o3:l0;
 i1+="\074tr>";
 for (var g=0;
 g<O3;
 g++){var l3=(i*l0)+g;
 i1+="\x3c\x74d c\x6cass=\x22imgCe\x6cl\042>";
 i1+=O1(o2[l3]);
 i1+="\074\x2f\x74d>";
 if (l2){i1+="\x3ctd \x63lass=\x22infoC\x65ll\042 wi\x64th=\042"+(0144/l0)+"\x25\x22>";
 i1+=I1(o2[l3]);
 i1+="\074/td>";
 }if (g<(l0-1)){i1+="\074td cla\x73s=\042verti\x63alSp\x61cer\042 rows\x70an=\x22"+((l2)?1: 2)+"\042>\074/td>";
 }}if (!l2){i1+="\x3c/t\x72>\074\164\x72>";
 for (var g=0;
 g<O3;
 g++){var l3=(i*l0)+g;
 i1+="\074\x74d \x63\154\x61ss=\x22infoC\x65ll\042 widt\x68=\042"+(0144/l0)+"\x25\042>";
 i1+=I1(o2[l3]);
 i1+="\074/td>";
 }}i1+="\x3c\x2ftr>";
 if (i<(i2-1)){i1+="\074tr>\074td cla\x73s=\x22horiz\x6fntalS\x70acer\x22 col\x73pan\x3d\042"+(l0*((l2)?3: 2)-1)+"\x22\x3e\074/td>\x3c/tr>";
 }}i1+="\x3c\x2ftabl\x65>";
 O2.innerHTML=i1;
 }}function I2(o2,O0){var i3=o2.length;
 if (i3>O0){if ((i3/2)>O0){var I3=o2;
 o2=[ ];
 for (var i=0,j=O0;
 i<j;
 i++){var o4=Math.floor(Math.random( )*I3.length);
 o2.push(I3[o4]);
 I3.splice(o4,1);
 } delete I3;
 }else {for (var i=0,j=(i3-O0);
 i<j;
 i++){var o4=Math.floor(Math.random( )*o2.length);
 o2.splice(o4,1);
 }}}return o2;
 }} ;


