Added logic so that the navigation buttons only appear if the user is logged in
Login function checks for cookie.  If users is logged in redirect them to the post page