Write jQuery code with getMessages() and updateView(messages) functions and click function on #send button