Groups
Groups
Sign in
Groups
Groups
CPHPUG-中国PHP用户组
Conversations
About
Send feedback
Help
问下Web聊天
7 views
Skip to first unread message
YiZhi Liu
unread,
Oct 23, 2009, 3:14:11 AM
10/23/09
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to cph...@googlegroups.com
服务器端应该用什么存放对话呢?是放在数据库里还是放在临时文件里?
另外编写手机客户端,如果想使用Web聊天接口,每隔几秒发送一个请求是否会造成流量太大?有什么好的解决方法吗?
庆亮
unread,
Oct 23, 2009, 9:41:54 PM
10/23/09
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to cph...@googlegroups.com
1. 建议放在内存中,如memcache,如果需要离线消息之类的功能,则需要数据库或者文件系统的配合。
2.基于传统web的im,循环请求是个快速的方法。对于手机来说可能这部分的流量的确不小,但具体的还是要看你的应用。可以根据具体情况调整请求时间,保证请求来的数据从概率上说多数都是有效的。 (请求的结果返回为没有新的数据,则为无效)
YiZhi Liu
unread,
Oct 27, 2009, 9:55:16 AM
10/27/09
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to cph...@googlegroups.com
谢谢~
2009/10/24 庆亮 <
qing.l...@gmail.com
>:
Reply all
Reply to author
Forward
0 new messages