WEB-IM 问题
1、easemob.im-1.0.5.js 有个发送给http://im-api.easemob.com/http-bind/的请求,会出现跨域请求
已阻止跨源请求:同源策略禁止读取位于 http://im-api.easemob.com/http-bind/ 的远程资源。(原因:CORS 请求失败)。
2、restapi,有登录的接口吗?
3、登录成功后,获取好友
conn.getRoster({
success : function(roster) {
该方法返回值各个属性代表什么,好像没有找到说明的地方,而且返回的好友跟我使用http://www.easemob.com/docs/rest/userapi/#queryfriend接口返回值不同
已阻止跨源请求:同源策略禁止读取位于 http://im-api.easemob.com/http-bind/ 的远程资源。(原因:CORS 请求失败)。
2、restapi,有登录的接口吗?
3、登录成功后,获取好友
conn.getRoster({
success : function(roster) {
该方法返回值各个属性代表什么,好像没有找到说明的地方,而且返回的好友跟我使用http://www.easemob.com/docs/rest/userapi/#queryfriend接口返回值不同
没有找到相关结果
已邀请:
3 个回复
beyond - imgeek运营
赞同来自: fat1
2:服务端没有登录的概念
3:这里获取好友是要分单向和双向的,both为双方互为好友,要显示的联系人,from我是对方的单向好友,to表明了联系人是我的单向好友。可以参考demo index里面的实现!
shep
已阻止跨源请求:同源策略禁止读取位于 http://im-api.easemob.com/http-bind/ 的远程资源。(原因:CORS 请求失败)。这个问题怎么解决?
lizg - ……