$(function() {
  $("input[type=text][title].behavior-show-hide").each(function() { var ds = $(this).attr("title"); $(this).val(ds); if($.trim($(this).val()) == "") $(this).val(ds); $(this).focus(function() { if($(this).val() == ds) $(this).val(""); }).blur(function() { if($.trim($(this).val()) == "") $(this).val(ds); }); }); //input behaviors
  $("a[href][rel*=external]").each(function() { $(this).attr("target", "_blank"); }); //external links
  $(".lo").hoverIntent(function() { $(this).removeClass("lo").addClass("hi"); }, function() { $(this).removeClass("hi").addClass("lo"); }); //hi/lo
  
  $("form.w > ul > li:not(.buttons)").each(function() {
    var $$ = $(this);
    $$.find(":input").each(function() { 
      $(this).focus(function() {
        $$.addClass("focused");
      }).blur(function() {
        $$.removeClass("focused");
      });
    });
  }); //determining li parents for w forms
  
  $("#sidenav > ul > li").hoverIntent(function() { $(this).removeClass("lo").addClass("hi").find("ul").show("slide"); }, function() { $(this).removeClass("hi").addClass("lo").find("ul").hide("slide"); });
  if (!$.browser.msie6) $("#nav > ul > li").find("ul").show().hide().end().hoverIntent(function() { $(this).removeClass("lo").addClass("hi").find("ul").show("blind"); }, function() { $(this).removeClass("hi").addClass("lo").find("ul").hide("blind"); });
  
  //ie6
  if ($.browser.msie6) {
    $("#body").fixMinHeight();
    $("#site-search-box").height("22px");
    $("#footer").fixBox();
    
    $.ifixpng("images/reusable/pixel.gif");
    $("img[@src$=.png]").ifixpng();
  }
});