var cycle = function(){
    var curr = $('img.current');
    var next = (curr.next('img').length ? curr.next('img') : $('#col2 img:first'));
    curr.hide().removeClass('current');
    next.fadeIn(2000).addClass('current');
}

$(function(){
   //setInterval('cycle()',5000);
});

var base_url = window.location.protocol + '//' + window.location.hostname + '';

$('body').delegate('#signup','submit',function(e){
	var email = $('#email').val();
	if (email.length){
		$.post(base_url + '/subscribe.php',{email:email},function(){
		});
		$(this).html('<h2>Thank you for subscribing</h2>');
	} else {
		$('#email').focus();
	}
	e.preventDefault();
});

