Dark caverns chat room - Updating database using php
Notice that we have added square brackets  to the name of the checkbox element.The reason for the square brackets is that it informs PHP that the value may be an array of information.Next we convert the new line characters in the text area into HTML line breaks.
Both send variables across to a script, but they do so in different ways.
The GET method sends its variables in the web browsers URL, which makes it easy to see and possibly change the information that was sent.
When you submit your HTML form PHP automatically populates two superglobal arrays, $_GET and $_POST, with all the values sent as GET or POST data, respectively.
Therefore, a form input called 'Name' that was sent via POST, would be stored as $_POST['Name'].
We are returning data in a json format to minimize the connection overload and make application faster.