lib/public/js/browse.js
function create_header_col(m) {
    var $e = $$('hcol nowrap');
    $e.css({width: p});
    if (m.options) {
      $e.css(m.options);
    }
    $e.text(m.name);
    var hilight = function () {
      if (!order)
        return;
      if (order == m.name)
      {
        $e.addClass('order asc');
        $lh = $e;
      }
      else if (order.substring(1) == m.name)
      {
        $e.addClass('order desc');
        $lh = $e;
      }
    }
    hilight();
    $e.click(function () {
      if (order == m.name) {
        order = '-' + m.name;
      }
      else {
        order = m.name;
      }
      zcookie.set('order-'+type, order);
      if ($lh)
        $lh.removeClass('order asc desc');
      hilight();
      $lh = $e;
     request_data();
    });
    return $e;
  }
function create_header_col(m) {
    var $e = $$('hcol nowrap');
    $e.css({width: p});
    if (m.options) {
      $e.css(m.options);
    }
    $e.text(m.name);
    var hilight = function () {
      if (!order)
        return;
      if (order == m.name)
      {
        $e.addClass('order asc');
        $lh = $e;
      }
      else if (order.substring(1) == m.name)
      {
        $e.addClass('order desc');
        $lh = $e;
      }
    }
    hilight();
    $e.click(function () {
      if (order == m.name) {
        order = '-' + m.name;
      }
      else {
        order = m.name;
      }
      zcookie.set('order-'+type, order);
      if ($lh)
        $lh.removeClass('order asc desc');
      hilight();
      $lh = $e;
     request_data();
    });
    return $e;
  }
function create_header_col ( m ) { var $e = $$ ( 'hcol nowrap' ) ; $e . css ( { width : p } ) ; if ( m . options ) { $e . css ( m . options ) ; } $e . text ( m . name ) ; var hilight = function ( ) { if ( ! order ) return ; if ( order == m . name ) { $e . addClass ( 'order asc' ) ; $lh = $e ; } else if ( order . substring ( 1 ) == m . name ) { $e . addClass ( 'order desc' ) ; $lh = $e ; } } hilight ( ) ; $e . click ( function ( ) { if ( order == m . name ) { order = '-' + m . name ; } else { order = m . name ; } zcookie . set ( 'order-' + type , order ) ; if ( $lh ) $lh . removeClass ( 'order asc desc' ) ; hilight ( ) ; $lh = $e ; request_data ( ) ; } ) ; return $e ; }
last header clicked
last header clicked