jQuery(document).ready(function(){
	// SLIDESHOW HOME
	$('div.slides').cycle({ 
		fx:     'scrollDown',
		speed:	500,
		timeout: 5000,
		delay:	-500
	});
	// SLIDESHOW SUBPAGE
	$('div.subSlides').cycle({ 
		fx:		 'fade',
		speed:	 1500,
		timeout: 5000,
		delay:	 -1500,
		random:	true,
		pager:	 '#nav' 
	});
});

// INPUTFOCUS I IE6/7
sfFocus = function() {
    var sfEls = document.getElementsByTagName("INPUT");
    for (var i=0; i<sfEls.length; i++) {
    	sfEls[i].onfocus=function() {
    		this.className+=" sffocus";
    	}
    	sfEls[i].onblur=function() {
    		this.className=this.className.replace(new RegExp(" sffocus\\b"), "");
    	}
}}
if (window.attachEvent) window.attachEvent("onload", sfFocus);

// SEARCH FIELD VALUE SWAP
$(function() {
    swapValues = [];
    $(".sv").each(function(i){
        swapValues[i] = $(this).val();
        $(this).focus(function(){
            if ($(this).val() == swapValues[i]) {
                $(this).val("");
            }
        }).blur(function(){
            if ($.trim($(this).val()) == "") {
                $(this).val(swapValues[i]);
            }
        });
    });
});


