$_SESSION['normal_user'] = $_POST['email'];
        } else {
            $status .= "<p style=\"padding-bottom: 50px\">Sorry, we could\n                  not log you in with that email address\n                  and password.</p>";
        }
    }
}
if ($action == 'log-out') {
    unset($action);
    $_SESSION = array();
    session_destroy();
}
/**********************************************************************
* Section 2: set up and display headers
*********************************************************************/
// set the buttons that will be on the tool bar
if (check_normal_user()) {
    // if a normal user
    $buttons[0] = 'change-password';
    $buttons[1] = 'account-settings';
    $buttons[2] = 'show-my-lists';
    $buttons[3] = 'show-other-lists';
    $buttons[4] = 'log-out';
} else {
    if (check_admin_user()) {
        // if an administrator
        $buttons[0] = 'change-password';
        $buttons[1] = 'create-list';
        $buttons[2] = 'create-mail';
        $buttons[3] = 'view-mail';
        $buttons[4] = 'log-out';
        $buttons[5] = 'show-all-lists';
function check_logged_in()
{
    return check_normal_user() || check_admin_user();
}