Home  >  Article  >  Backend Development  >  Chat program using line writing (Part 1)_PHP tutorial

Chat program using line writing (Part 1)_PHP tutorial

WBOY
WBOYOriginal
2016-07-13 17:31:311199browse


In the early stage, I saw the very small version of the chat program of mdjwq@yeah.net and Daoxiangju’s Red Dragonfly. I read their code carefully and felt that this was a rare code, especially for those who had just read it. For beginners, some techniques are used in the program, which are of great reference value. Based on their code and my own experience, I added some functions (management of online personnel, etc.), and changed the implementation method from TXT to MySQL (the best combination with PHP) . All programs are in All local debugging has passed. I hope that netizens who have their own chat programs can use it directly. After my personal homepage is completed, it will be used in conjunction with the forum (the forum has been fully installed, and other content will also be migrated from chinaren to oso), and an Oracle (large website database platform) and MySQL will be opened (The best combination with PHP)Database administrator’s information discussion board.
Forum information table:
create table lt_t_online /* Record online personnel information*/
( /* Name, last speaking time, IP address, status (0 online, 1 offline) */
lt_username varchar(12)                                                                                                                                                                                                                                                                                                    _state char(1) not null
);

create table lt_t_content / * Chat information table */
( /* Speaker, object, confidentiality level, expression, color, content, time */
lt_speaker varchar(12) not null,
lt_speaked varchar(12) not null,
lt_secrecy char(1) not null,
lt_face smallint null,
lt_color var char(6)                                                                                                                                                                                                                                                                                                     . ;
.
The program consists of five parts:



http://www.bkjia.com/PHPjc/509053.html

www.bkjia.com

true

TechArticleIn the early stage, I saw a very small version of the chat program between mdjwq@yeah.net and Daoxiangju’s Red Dragonfly , read their code carefully and feel that this is a rare code, especially for those who are just getting started...
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn