//Default settings for onLoad
$(document).ready(function () {
	//nyroModal settings
	$.fn.nyroModal.settings.bgColor = '#444';
 	$.fn.nyroModal.settings.minHeight = 30;
 	$.fn.nyroModal.settings.minWidth = 50;
 	//Rounded corners
 	$('#mainContainer').corner('15px');
 	$('#bannerContainer').corner('15px');
 	$('#nav_menu .active').corner('10px tr tl');
 	$('#nav_menu li a').corner('10px tr tl');
 	$('#contentContainer').corner('15px tr br bl');
 	$('.sidebox').corner('15px bl br');
 	$('.sideboxTitle').corner('15px tr tl');
 	$('.fullbox').corner('15px bl br');
 	$('.fullboxTitle').corner('15px tr tl');
 	$('.inbox').corner('15px tr tl');
 	$('.linkst').corner('15px tr tl');
 	$('.linksb').corner('15px br bl');
 	$('.blocktable h2').not(".noRound").corner('15px tr tl');
 	$('.block h2').not(".noRound").corner('15px tr tl');
 	$('.blockform h2').not(".noRound").corner('15px tr tl');
 	$('.blockmenu h2').not(".noRound").corner('15px tr tl');
 	$('h2.doRound').corner('15px tr tl');
 	$('.box').corner('15px br bl');
});
//Custom wait function
$.fn.wait = function(time, type) {
	time = time || 1000;
	type = type || 'fx';
	return this.queue(type, function() {
		var self = this;
		setTimeout(function() {
			$(self).dequeue();
		}, time);
	});
};
$(document).ready(function() {

    	$('#account_add').ajaxForm({
        	target: '#account_add_result',
        	beforeSubmit: function() {
        		$('#account_add_result').empty();
        		$('#account_add_result').show();
        		$('#account_add_result').append('<img src="img/ajax-loader.gif" alt="O" style="margin-top:3px" /> Please wait...');
        	},
        	success: function() {	
        		$('#account_add_result').hide();
            		$('#account_add_result').fadeIn(750);
        	}
    	});
});