/**
 * form functions...
 */
/**
 * show all day form for given date and venue id
 * POPUP window!!!
 */
$(function(){    
	setupForm();
});


/**
 * do tool tip
 * and links
 * @return void
 */
function setupForm()
{
	$('a.new-window').tooltip({ 
        track: true, 
        delay: 0, 
        showURL: false, 
        showBody: " || ", 
        fade: 250 
    });
	
//	$('a.new-window').click(function(){
//        window.open(this.href, 'raceDetails', 'menubar=0,resizable=1,width=900,height=700');
//        return false;
//    });
	
}// end setupForm


function showHelp(link)
{
	window.open(link, 'legend', 'menubar=0,resizable=1,width=900,height=500');
	
}// end show help


/**
 * get venues by date
 * use AJAX to post to id:
 * 'main_content'
 */
function getVenuesByDate(date)
{
	window.location.replace(baseUrl + '/date/' + date);
//	$('#main_content').load(baseUrl + '/date/' + date, '', function(){
//		setupForm();
//	});
	// run do tooltip again...
	
}// end getVenuesByDate