php网页版聊天软件实现代码
发布时间:2020-05-23 10:39:05 所属栏目:PHP 来源:互联网
导读:这篇文章主要介绍了php网页版聊天软件实现代码,可以实现匿名聊天,感兴趣的小伙伴们可以参考一下
|
本文实例为大家分享了php匿名聊天室的具体实现代码,供大家参考,具体内容如下 1. index.html <div class="panel panel-default" id="main"> <div class="panel-heading"> 2. action.php $link = mysqli_connect('localhost','root','123','test');mysqli_query($link,'set names utf8'); $info= array(); header("Content-type: text/html; charset=utf-8"); $id=$_GET['maxid']; $data = mysqli_query($link,"select * from talk where id>$id"); while ($array = mysqli_fetch_assoc($data)) { $info[] = $array; }; echo json_encode($info); 3. chat.sql 4. add.php /**
(编辑:安卓应用网) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |
