Home arrow MySQL arrow A MySQL Driven Chat Script
MYSQL

A MySQL Driven Chat Script


In this article, Tim will show you how to create a quick-n-easy chat script using PHP and a very simple MySQL database. The script will allow visitors to choose a nickname, enter text to send to the chatting window, and view messages from other people... all in real-time! For a bit of fun, the chat application also has buttons to send several emote-icons including smiling and frowning faces.

Author Info:
By: Tim Pabst
Rating: 4 stars4 stars4 stars4 stars4 stars / 252
December 25, 2001
TABLE OF CONTENTS:
  1. · A MySQL Driven Chat Script
  2. · Creating the database
  3. · The chat script explained
  4. · The chat script explained (contd.)
  5. · The chat script explained (contd.)
  6. · Conclusion

print this article
SEARCH DEVARTICLES

A MySQL Driven Chat Script
(Page 1 of 6 )

One of the most popular uses for the Internet is person-to-person communication. There are many ways that we can communicate with each other online including ICQ, MSN Messenger, forums, Email, mIRC and Java chat applets. If you run a web site, then you should provide your visitors with some sort of communication tool that will allow them to express their opinions on a particular topic, as well as communicate with other people sharing the same interests as them.

In this article, I’m going to show you how to create a quick-n-easy chat script using PHP and a very simple MySQL database. The script will run in a web browser and the chats will be stored in a database. Our script will allow the visitor to choose a nickname, enter text to “send” to the chatting window, and view messages from other people… all in real-time! For a bit of fun, our chat application will also have buttons to send several emote-icons including smiling and frowning faces.

In this article, I am assuming that you know how to create a MySQL database from the command line. I will also assume that you have Apache, PHP and MySQL on the same server running under Windows 2000. If you’re running a Win9x/Unix box, don’t worry…everything is pretty much the same.

Firstly, let’s start by creating the database to store our chat sessions…
blog comments powered by Disqus
MYSQL ARTICLES

- MySQL and BLOBs
- Two Lessons in ASP and MySQL
- Lord Of The Strings Part 2
- Lord Of The Strings Part 1
- Importing Data into MySQL with Navicat
- Building a Sustainable Web Site
- Creating An Online Photo Album with PHP and ...
- Creating An Online Photo Album with PHP and ...
- PhpED 3.2 – More Features Than You Can Poke ...
- Creating An Online Photo Album with PHP and ...
- Creating An Online Photo Album with PHP and ...
- Security and Sessions in PHP
- Setup Your Personal Reminder System Using PHP
- Create a IP-Country Database Using PERL and ...
- Developing a Dynamic Document Search in PHP ...

Watch our Tech Videos 
Dev Articles Forums 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
Contact Us 
Site Map 
Privacy Policy 
Support 

Developer Shed Affiliates

 




© 2003-2014 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap
Popular Web Development Topics
All Web Development Tutorials