HTML and CSS Reference
Listing 4.6. Add a chat message (client code)
Step 6: Store new chat messages in the database
On the server you'll need a script to insert the chat messages in the database as they're
created. The next listing shows the source code for add-chat.php, which grabs the message
from a POST request and stores it with the appropriate details.