// если ссылка содержит путь схожий с тем где сейчас находится броузер, то она получит класс act
base=$('base').attr('href');if(base){$('a').each(function(){if(base.indexOf(this.href)>-1)$(this).addClass('act');});}

// если у таблицы установлен бордер, то применяем к ней оформление
$('table[border=1]').attr('border',0).attr('cellspacing',1).css('background','#ccCCcc').find('td').css('background','#ffFFff');

// делает кнопки форм одинаковыми во всех броузерах
$('input[type=button],input[type=submit]').each(function(){
  $(this).wrap('<span>').parent().attr('class','button')
  $(this).focus(function(){
    $(this).blur()
  })
});

// растягивает сайт по высоте если необходимо
function he(){
  x = (window.innerHeight ? window.innerHeight : document.documentElement.clientHeight)-181;
  x = document.getElementById('hif').offsetHeight>x ? document.getElementById('hif').offsetHeight : x;
  if(document.getElementById('hof').style.height!=x){
    document.getElementById('hof').style.height = x+'px';
    win_h = x;
  }
}
he();setInterval(he,1000);

