Added new action: getPost, also re-arranged the action switch statement