function isDateLessThan3YearAgo(month, year)
{
    var today = new Date();
    var currentMonth = today.getMonth() + 1;
    var currentYear = today.getFullYear();
    
    if((currentYear - year > 3) || (currentYear - year == 3 && currentMonth > month))
    {
        return false;
    }
    
    return true;
}

function setFormTextBoxVisible(id, visible)
{
    $("input").filter(function(index){return $(this).attr("id").indexOf(id) > -1}).css("display", visible);
    $("label").filter(function(index){return $(this).attr("for").indexOf(id) > -1}).css("display", visible);
}

function changeAddressCountry(control, clientId, countryList)
{	    	    
    if(countryList == null || countryList == '' || countryList.toUpperCase().indexOf(control.options[control.selectedIndex].value.toUpperCase()) > -1)
    {
        setFormTextBoxVisible(clientId, "block");
    }
    else
    {
        setFormTextBoxVisible(clientId, "none");
    }
}

function initTabber(tabberId, activeTab) {
    	var selector = "#" + tabberId;
    	if($.browser.safari)
	        $(selector + " > div").css("display", "block");
	    var tabber = $(selector + " > ul").tabs({ fx: { height: 'toggle', opacity: 'toggle'} });             
        tabber.tabs('select', activeTab);
        $(selector + " > ul").css("display", "block"); 
}