function createAccount()
{
    $tabs.tabs('add', 'php/content.php?page=createAccount', 'Create an account');
    accountTabIndex=$tabs.tabs('length')-1;
    $tabs.tabs('select', accountTabIndex);
}

function saveAccount()
{
    $("#accountPassword").val(sha1($("#accountPassword").val()));
    $("#accountPasswordConfirm").val("");  //we don't need this value after we've verified the form, and there's no need to send sensitive data out as a post
    var variables=$("#createAccountForm").serialize();
    variables+="&action=createAccount";
    $.post("php/siteActions.php",variables, function(response){
	    checkCookie();
	    showSignedIn();
	    loadSignupsPage();
	    //	    loadCreatePage();
	    loadInitialMeetingPage();
	    $tabs.tabs('select', '#mainPage');
	    $tabs.tabs('remove', accountTabIndex);
	    $("div#notifications").html("Enjoy your brand new Meetlie account!");
	    $("div#notifications").show();
	});
}

function cancelAccountCreate()
{
    $tabs.tabs('remove', accountTabIndex);
}