/* Author: Joe Buckle (http://www.white-fire.co.uk) */

// CHECK FOR MICRODATA SUPPORT
function supports_microdata_api() {
  return !!document.getItems;
}

// SLIDE SWITCH FUNCTION
function slideSwitch() {
        var $active = $('.banner div.active');
            if ( $active.length == 0 ) $active = $('.banner div:last');
            var $next =  $active.next().length ? $active.next(): 
                $('.banner div:first');

            $active.addClass('last-active');
            $next.css({opacity: 0.0}).addClass('active')
            .animate({opacity: 1.0}, 1000, function() { 
            $active.removeClass('active last-active');
        });
}

$(document).ready(function(){
    
// INLINE FORM VALUES
    $(':input[title]').each(function() {
        var $this = $(this);
        if($this.val() === '') {
            $this.val($this.attr('title'));
        }
        $this.focus(function() {
        if($this.val() === $this.attr('title')) {
            $this.val('');
        }
    });
    $this.blur(function() {
        if($this.val() === '') {
            $this.val($this.attr('title'));
        }
    });
    });
    
    
	// FADING BANNER 
		$(function() {		
			setInterval( "slideSwitch()", 3000 ); 
		});    
		
// END SCRIPT    
});    




















