$(document).ready(function() {

$('#featureCycle').before('<div id="featureThumbs">').cycle({ 
    fx:     'fade', 
    speed:  'slow',
    speedIn: 1000,
    speedOut: 1000,
    timeout: 5000, 
    pager:  '#featureThumbs', 
    slideExpr: 'img' ,
    after:     function() {
            $('#caption').html(this.alt);
           },
    // callback fn that creates a thumbnail to use as pager anchor 
    pagerAnchorBuilder: function(idx, slide) { 
    
        return '<a href="'+slide.parentNode.href+'"><div>'+slide.alt+'</div><img src="' + slide.src + '" width="170" height="130" alt="" class="slide" /></a>'; 
    } 
});

$(".slide").mouseover(function(){
$(this).fadeTo("slow", 0);
});

$(".slide").mouseout(function(){
$(this).fadeTo("slow", 1);
});

$(".slide").click(function(){
var newlocation = $(this).parent().attr("href");
window.location = newlocation;
});

});

