Chat functions of mobile apps

Source: Internet
Author: User
PHP is used on the server and is based on the thinkphp framework. Android is used on the Mobile End, and many interfaces can be used on the Internet. How to Design the backend database? Can you provide some ideas or some useful tutorials, or do you need to use other technologies? Node? The server uses PHP and is based on the thinkphp framework. Android is used on mobile terminals,
Then there are many interfaces available on the internet,
How to design background databases?
Can you provide some ideas or some useful tutorials,
Or do we need to use other technologies? Node?

Reply content:

The server uses PHP and is based on the thinkphp framework. Android is used on mobile terminals,
Then there are many interfaces available on the internet,
How to design background databases?
Can you provide some ideas or some useful tutorials,
Or do we need to use other technologies? Node?

If you are not a software enterprise focusing on IM, IM functions do not need to be designed by yourself. You only need to access some existing services to complete simple instant chat functions.

Refer to IM service
Https://leancloud.cn /?
Http://www.arrownock.com/impp
Http://netease.im/
Http://www.rongcloud.cn/
Http://www.easemob.com/

The third-party im service we initially used in our project is helpless.
Later I changed it to workerman. The effect is not bad yet.

You need to know about the push-related technologies.

Since the landlord chose php, it is recommended that you try workerman as the chat function framework, which does not interfere with the original system, and both are php. There is no other learning cost, and the workerman documentation is complete, active Communities and mature products in use

Based on workerman + angularjs, I wrote one myself some time ago;

Mobile phones can be normally used by browsers supporting websocket, such as mobile chrome.

Demo address: http://say.wunao.net/

PHPWebIM is an official WebSocket webpage instant chat tool developed by Swoole based on PHP Swoole extension and Swoole Framework. PHPWebIM supports WebSocket + Comet protocols and can be used in all types of browsers, including IE.
Https://github.com/matyhtf/PHPWebIM
Demo: http://webim.swoole.com/

PHPWebIM communication structure based on Swoole:
1. The server is provided by Nginx/PHP-FPM for HTTP services, such as listening to port 80:
The browser accesses the http://im.swoole.com/main.html to get the data produced by the Nginx/PHP-FPM service.
2. The WebSocket Service (CLI program) implemented by PHP Swoole listens to a port separately, such as 9503:
Use JavaScript to access ws: // im.swoole.com: 9503 on the main.html page to obtain the data generated by the WebSocket service.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.