// Copyright (c) 2006 Jay Jones
//
// Big Hover
//
// Searches a passed element name for specified class, and converts
// that element into an <a href>... giving the element a new class name as well.
//
// format is: clickArea(tagName, className, hoverClass)
//
// Example:
// window.onload=function(){
//    clickArea("div", "bybiglink", "mybighover");
// 	 if(!NiftyCheck())
//     return;
// 		Rounded("div#footer-note","all","#00659e","#127cb8");
// }
//

/*--------------------------------------------------------------------------*/

function clickArea(tagName, className, hoverClass) {
	var els = document.getElementsByTagName(tagName);
	for (var i = 0, len = els.length; i < len; i++) {
	  if (els[i].className.indexOf(className)>=0) {
  		els[i].onmouseover=function() {
  			this.className+=" " + hoverClass;
  			window.status = this.getElementsByTagName("a")[0].href;
  			return true;
  		};
  		els[i].onmouseout=function() {
  			this.className=this.className.replace(new RegExp(" " + hoverClass + "\\b"), "");
  			window.status = "";
  			return true;
  		};
  		els[i].onclick = function () {
  		  location.href = this.getElementsByTagName("a")[0].href;
  		}
    }
  }
}

clickArea("div", "biglink", "soopahover");
clickArea("div", "side_biglink", "side_soopahover");


jQuery.noConflict();
(function($) {
  var $searchForm = $('#search-form');
  $('#search-input, #search-submit').focus(function() {
    $searchForm.addClass('active');
  }).blur(function() {
    $searchForm.removeClass('active');
  });
  $('#search-input').defaulttext();    
})(jQuery);

/*
// disabled per client 5/25/10 
jQuery(document).ready(function($) {
  	if (!$.cookie('splash')) {
      $('#promise-splash-link').fancybox({
        overlayColor: '#fff',
        overlayOpacity: '.9',
        padding: 0,
        autoScale: false        
      }).trigger('click');
      $.cookie('splash', 'show', {expires: 1, path: '/'});
    }
});
*/