• 首页
  • 动态
  • 案例
  • 引擎社区
  • API
  • 文档
  • 示例
  • 引擎下载

大约有 45 项符合查询结果, 库内数据总量为 30,724 项。 (搜索耗时: 0.0027 秒)

21. 最新版本IDE,如何获取http返回的json数据 [ 66%]

...le.log ('按了登录按钮')  var xhr = new Laya.HttpRequest(); xhr.http.timeout = 10000;//设置超时时间; xhr.once(Event.COMPLETE,this,completeHandler); xhr.once(Event.ERROR,this,errorHandler); xhr.once(Event.PROGRESS,this,processHandler);  var sendData = {account:"aaa",password:"bbb"} xhr...

来源: Laya_社区 发布时间: 20180824

22. 排坑:Laya.HttpRequest()无效 [ 65%]

... console.log("开始测试"); var xhr = new Laya.HttpRequest(); xhr.http.timeout = 10000;//设置超时时间; xhr.once(Event.COMPLETE, this, completeHandler); xhr.once(Event.ERROR, this, errorHandler); xhr.on(Event.PROGRESS, this, processHandler); xhr.send("http://www.baidu.com", "", "get", "text...

来源: Laya_社区 发布时间: 20180208

23. 手机调试时http请求错误,返回Request failed Status:0 [ 64%]

...解决?下面是代码片段: let hr = new Laya.HttpRequest(); hr.http.timeout = 5000; hr.on(Laya.Event.PROGRESS, this, this.onHttpRequestProgress); hr.once(Laya.Event.COMPLETE, this, (response)=>{ UIFactory.closeWaitBar(); this.onHttpRequestComplete(response); if(handleOk){ handleOk(response...

来源: Laya_社区 发布时间: 20190308

24. 打包成APK后,POST请求会先去Download请求的地址 [ 62%]

.../xxx.yyy.cn/api 03-09 21:15:03.201 23554 23645 W LayaBox : download error: timeout, dt=8,opttimeout=1798 03-09 21:15:03.207 23554 23663 I LayaBox :  [addChild][BoundReference]   download 成功log: ↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓ 03-09 21:15:16.950 23554 2...

来源: Laya_社区 发布时间: 20180315

25. 调试总是中断了 [ 62%]

调试总是中断了 Cannot connect to runtime process, timeout after 10000 ms - (reason: Can't attach to this target that may have Chrome DevTools attached - file:///D:/work/SlotProject2/bin/index.html). 2017-04-28 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已...

来源: Laya_社区 发布时间: 20170428

26. xhr的on和once什么区别,官网例子 [ 60%]

... Laya.init(1136, 640); var xhr:HttpRequest = new HttpRequest(); xhr.http.timeout = 10000;//设置超时时间; xhr.once(Event.COMPLETE,this,completeHandler); xhr.once(Event.ERROR,this,errorHandler); xhr.on(Event.PROGRESS,this,processHandler); 2017-10-17 添加评论 免费帖 --> 分享 微博 QZO...

来源: Laya_社区 发布时间: 20171017

27. 分享:常见 IDE 错误提示解决方案 [ 60%]

...型2:   报错类型3: IDE错误:Cannot connect to runtime process, timeout after 10000 ms - (reason: Cannot connect to the target: connect ETIMEDOUT 127.0.0.1:9222).------可以参考开发者的解决方式(http://ask.layabox.com/question/4392)   以上报错可能是端口号冲突导...

来源: Laya_社区 发布时间: 20170518

28. gps定位获取当前城市名字 [ 60%]

...VAILABLE: alert("暂时获取不到位置信息"); break; case Geolocation.TIMEOUT: alert("获取位置信息超时"); break; default: alert("加载地图时出现未知错误"); break; } })); }else alert("不支持"); 为毛获取不到 2017-02-23 添加评论 免费帖 --> 分享 微博 QZONE 微...

来源: Laya_社区 发布时间: 20170223

29. Laya.HttpRequest 没有调用回调方法? [ 58%]

...化引擎 Laya.init(1136,640); var xhr = new Laya.HttpRequest(); xhr.http.timeout = 10000;//设置超时时间; xhr.once(Event.COMPLETE,this,completeHandler); xhr.once(Event.ERROR,this,errorHandler); xhr.on(Event.PROGRESS,this,processHandler); xhr.send("https://www.baidu.com/","","get","text"); fu...

来源: Laya_社区 发布时间: 20180830

30. 官方的示例贴上来,怎么没反映啊 [ 57%]

...on JiHuo() { JiHuo.super(this); var xhr = new Laya.HttpRequest(); xhr.http.timeout = 10000;//设置超时时间; xhr.once(Event.COMPLETE, this, completeHandler); xhr.once(Event.ERROR, this, errorHandler); xhr.on(Event.PROGRESS, this, processHandler); xhr.send("https://api.weixin.qq.com/cgi- ... ot...

来源: Laya_社区 发布时间: 20180419