// Copyright (c) 2003-2005 Y-Times Publications, LLC. All Rights Reserved.
// Duplication is not permitted without written permission of Y-Times Publications, LLC.


function ShowBSells(cols)
{
    var FeaturedIndex = new Array;
    var elems = 0;
    do
    {
      idx = Math.floor( Math.random() * Featured.length );
      var IdxFound = false;
      for (i = 0; i < FeaturedIndex.length; i++ )
      {
        if (FeaturedIndex[i] == idx)
        {
          IdxFound = true;
          break;
        }
      }
      if (!IdxFound)
      {
        FeaturedIndex[elems] = idx;
        elems = elems + 1;
      }
    } while (FeaturedIndex.length < FeaturedN);

    document.write("<table border=0 width=100% cellpadding=0 cellspacing=0><tr valign=top align=center>");
    for (i = 0 ; i < FeaturedIndex.length; i++)
    {
        if ((i+1) % cols == 0)
            document.write("<td class=rbsLastCell ");
        else
            document.write("<td class=rbsMidCell ");
        document.write( " width=" + (100/cols) + "%>" + String(Featured[FeaturedIndex[i]]).replace(/`/gi, "'") + "</td>");
        if ((i+1) % cols == 0)
        {
            document.write("</tr><tr valign=top align=center>");
        }
    }
    document.write("</tr></table>");
}

