返回顶部
摘要: 1.群聊 web socket 基于TCP/UDP http 无状态的短链接 长连接:客户端和服务器保持永久性的链接,除非有一方主动断开, 轮询:客户端和服务端不断连接,然后断开,请求响应;不能保证数据的实时性. 长轮询:长轮询:客户端发起请求至server,服务端不响应,服务端一直等待,链接一直建 阅读全文
posted @ 2019-08-15 09:22 高薪程序员 阅读(2299) 评论(0) 推荐(0) 编辑
摘要: 1.1Flask启动 1.2 Response 1. return "字符串" httpresponse 2. return render_template('html文件',变量='字符串') 默认存储位置是remplates,返回模板,依赖markupsafe包 3. return redire 阅读全文
posted @ 2019-08-15 09:16 高薪程序员 阅读(2467) 评论(0) 推荐(0) 编辑
摘要: API1.0使用方法: API2.0使用方法: import json import urllib.request import yuyinhecheng as hc def Tuling(text_input): api_url = "http://openapi.tuling123.com/op 阅读全文
posted @ 2019-08-15 09:09 高薪程序员 阅读(843) 评论(0) 推荐(0) 编辑