<!--
  function buildPageSelect()
  {
    var name1 = "";
    var name2 = "";
    
    var page = "Page";

    var a = document.URL;
    var a_low = a.toLowerCase();
    var b = a_low.indexOf("icatalog");
    var c = a_low.indexOf("&", b);
    var d = "";
    if (c != -1)
      d = a.substring(c);
    var e;
    var g = 1;  //  first page's number. This number is 2 for PFI interactive catalog

    if (a_low.indexOf("productsforindustry.com") != -1 || a_low.indexOf("p4i.com") != -1)
    {
      e = 846;
    }
    else if (a_low.indexOf("productos.com") != -1)
    {
      e = 396;
      page = "P&aacute;gina";
    }
    
    document.write("<td width='45%' height=10 align=right valign=middle style='color:#FF0000; text-decoration:none; font-family: Arial, Helvetica, sans-serif; font-size: 12px; font: bold;'>" + name1 + "</td>");
    document.write("<td width='10%' height=10 align=center valign=middle><select name='iCatalogPage' onChange='iCatalogGo()'>");
    if (a_low.indexOf("productsforindustry.com") == -1)
    {
    document.write("<option value=" + g + "></option>");
    }
    
    if (a_low.indexOf("productsforindustry.com") == -1)
    {
      if ( a_low.indexOf("p4i.com") != -1)
      document.write("<option value=" + g + ">" + page + " 2</option>");
    else
      document.write("<option value=" + g + ">" + page + " 1</option>");
    }

    var f;
    for ( f = 2; f < e;  f = f+2)
      document.write("<option value=" + f + ">" + page + " " + f + "-" + (f+1) + "</option>"); 

    if (e == f)
      document.write("<option value=" + e + ">" + page + " " + e + "</option>");
    document.write("</select></td>");
    document.write("<td width='45%' height=10 align=right valign=middle style='color:#0072BB; text-decoration:none; font-family: Arial, Helvetica, sans-serif; font-size: 12px; font: bold;'>" + name2 + " &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </td>");
  }

  function initiCatalogPage()
  {
    var a = document.URL;
    var a_low = a.toLowerCase();
    var b = a_low.indexOf("icatalog");
    var c = a_low.indexOf("/", b);
    var d = a_low.indexOf("&", c);
    
    var e;
    if (d != -1)
       e =  a_low.substring(c+1, d);
    else
      e =  a_low.substring(c+1);
    //  Deal with The DocPros format. Remove "0" and "t"
    while (e.substring(0, 1) == "t" || e.substring(0, 1) == "0")
    e = e.substring(1);
    if (e%2)   // if e is odd number, like 3, 5, 7...
      e = e - 1;

    if (a_low.indexOf("productsforindustry.com") == -1)
    {
    document.iCatalog.iCatalogPage.selectedIndex = (e/2)+1;      
  }
    else
    {
      document.iCatalog.iCatalogPage.selectedIndex = (e/2)-1;      
    }
  }

  function iCatalogGo()
  {
    var a = document.URL;
    var a_low = a.toLowerCase();
    
    //  06/24/04: Remove "tran_id" from URL if existing, otherwise will cause run time error
    var t = a_low.indexOf("tran_id=");
    if (t != -1)
    {
      var x = a_low.indexOf("&", t);
      if (x == -1)
        a = a.substring(0, t);
      else
        a = a.substring(0, t) + a.substring(x)
    }    
    a_low = a.toLowerCase();
  
    var b = a_low.indexOf("icatalog");
    var c = a_low.indexOf("/", b);
    var d = a_low.indexOf("&", c);
  
    var e = document.iCatalog.iCatalogPage.options[document.iCatalog.iCatalogPage.selectedIndex].value;
    var f;
    var g = "t";
    if (d != -1)
      f =  a.substring(0, c+1) + g + e + a.substring(d);
    else
      f =  a.substring(0, c+1) + g + e;
  
    window.location = f;
  }

  function openCatalog()
  {
    var a = document.URL;
    var a_low = a.toLowerCase();
    
    var catalog_page = document.product.cat_path.value;
    var b = catalog_page.split("."); 
    catalog_page = b[0].toUpperCase();

    catalog_page = catalog_page.substring(catalog_page.length-3);  //  remove prefix
      
    //  Deal with DocPros format, leave prefixed "0"
    var g = "0";
    document.location = 'http://' + location.hostname + location.pathname + '?template=iCatalog' + '/' + g + catalog_page + '&user_id=' + document.product.user_id.value + '&cust_no=' + document.product.cust_no.value + '&ship_no=' + document.product.ship_no.value;
  }
//-->