$(function() {
	var nickname = $( "#nickname" ),
		password = $( "#password" );

	$( "#dialog-login-form" ).dialog({
		autoOpen: false,
		height: 300,
		width: 400,
		modal: true,
		buttons: {
			"Login": function() {
				document.frmLogin.submit();
				$( this ).dialog( "close" );
			},
			"Register": function() {
				document.location.href = base_url + 'register';
				$( this ).dialog( "close" );
			},
			"Forgot password": function() {
				document.location.href = base_url + 'forgot-password';
				$( this ).dialog( "close" );
			},
			Cancel: function() {
				$( this ).dialog( "close" );
			}
		}
	});
	
	$( "#dialog-not-confirmed" ).dialog({
		autoOpen: false,
		height: 100,
		width: 300,
		modal: true
	});

});

function openLoginForm(){
	$( "#dialog-login-form" ).dialog( "open" );
}

function openNotConfirmedDialog(){
	$( "#dialog-not-confirmed" ).dialog( "open" );
}
