首页 \ 问答 \ 英特尔XDK中的HTTP请求(HTTP requests in Intel XDK)

英特尔XDK中的HTTP请求(HTTP requests in Intel XDK)

我之前在2月23日更新之前在英特尔XDK平台上构建了一个应用程序,现在软件已经更新,当我尝试运行模拟器它只是崩溃。

之前我通过以下方式向进程php页面发送了get请求以进行登录。

 $(document).ready(function(){
$('form.login').submit(function () {
var user = $(this).find("[name='user']").val();
var pass = $(this).find("[name='pass']").val();
var sublogin = $(this).find("[name='sublogin']").val();

// ...
    $.ajax({
type: "POST",
url: "http://www.domain.com/data/apps/project1/process.php",
data: {
    user : user,
    pass : pass,
    sublogin : sublogin,
},
 success: function(response){                       
        if(response == "1")
                    {

                     $("#responsecontainer").html(response);    

                    window.location.href = "menu.html"; 

                    }
                    // Login failed
                    else
                    {
                         $("#responsecontainer").html(response);  
                    }


        //alert(response);
    }
   });
      this.reset();
        return false;
      });
   });

但是,似乎这是导致问题的代码片段,如果我删除此项代码,项目不再崩溃。

当我阅读英特尔XDK文档时,它只显示调用XML文件的HTTP请求。

所以我希望有人可能知道为什么这会导致问题或我如何构建它以便英特尔XDK不会崩溃。


I previously built an app in the Intel XDK platform pre the Feb 23rd update and now the software has updated when i try to run the emulator it just crashes.

previously i sent a get request to a process php page for a login in the following way.

 $(document).ready(function(){
$('form.login').submit(function () {
var user = $(this).find("[name='user']").val();
var pass = $(this).find("[name='pass']").val();
var sublogin = $(this).find("[name='sublogin']").val();

// ...
    $.ajax({
type: "POST",
url: "http://www.domain.com/data/apps/project1/process.php",
data: {
    user : user,
    pass : pass,
    sublogin : sublogin,
},
 success: function(response){                       
        if(response == "1")
                    {

                     $("#responsecontainer").html(response);    

                    window.location.href = "menu.html"; 

                    }
                    // Login failed
                    else
                    {
                         $("#responsecontainer").html(response);  
                    }


        //alert(response);
    }
   });
      this.reset();
        return false;
      });
   });

However it seems that this is the piece of code that is causing the problems, if I remove this item of code the project no longer crashes.

When i read through the Intel XDK documents it only shows HTTP request to call XML files.

So i was hoping that somebody may know why this is causing the problem or how i might construct it so that Intel XDK doesn't crash.


原文:https://stackoverflow.com/questions/28702497
更新时间:2023-08-14 12:08

最满意答案

问题是一个覆盖,其内部有一个错误的ACL检查。


The Problem was an overlay which had a false ACL checking within.

相关问答

更多
  • 这样,Laravel只会按照您指定的凭据选择用户,如果您想检查用户拥有的状态以及要显示的视图,则可以覆盖登录控制器的authenticated()方法。 它可以访问已经登录的用户,所以请注意,你必须注销它的状态是无效的。 protected function authenticated(Request $request, $user) { if ( $user->status == 0 ) { auth()->logout(); return back()->wit ...
  • 我通过将这个JS脚本放入html5smartimage来扩展html5smartimage xtype var MyAppLib = MyAppLib || {}; MyAppLib.NamedHtml5SmartImage = CQ.Ext.extend(CQ.html5.form.SmartImage, { constructor : function(config) { config = config || {}; var defaults = { ...
  • 问题是一个覆盖,其内部有一个错误的ACL检查。 The Problem was an overlay which had a false ACL checking within.
  • 好。 最后想出了这个问题。 我想清除传递给我的处理程序的现有组件列表,我使用allowed = []; 。 这删除了对允许的数组的所有现有引用。 (更多关于此解释)。 因此将其更改为allowed.length = 0; 工作得非常好。 function MyHandler(cell, allowed, componentList) { allowed.length = 0; allowed.push("/libs/foundation/components/list"); } Ok. F ...
  • 我不是其背后推理的权威,也许一个对决策有远见的人可以介入,但据我所知,var最初是任何临时或派生数据的位置,但不一定是客户面对。 版本控制和一堆其他信息存储在那里,因此不应该向客户端公开。 / etc是一般在调度程序上保持打开的位置,因此如果查找信息属于SDLC的一部分,则放置查找信息的逻辑位置在此位置内。 如果查找是可授权的,那么将它放在/ content目录中会更明智,如果你正在做任何涉及多租户的事情都适合重写策略。 此外,如果不同的租户正在访问相同的查找数据,即 http://www.mysite.c ...
  • 您可以在jsp中编写带有表单的自定义组件以及提交按钮include。 在表单内部使用一个parsys(用于添加字段组件,如textfield,下拉列表,隐藏字段。这些字段在sidekick中的通用表单块组中)。 然后编写一个servlet以从表单提交。 这种方式只有表单路径和提交按钮将固定其余的字段作者可以随时随地任意数字。 You can write a custom component with form inside jsp along with submit button include. Insi ...
  • 当我们通过包移动内容时,我看到了类似的行为,最终创建了一个没有关联的jcr:content节点的页面。 这不必在您遇到问题的页面上,它可能是一个兄弟页面。 我会检查该网站下网页的完整性。 I've seen similar behaviour when we had content moved via a package and it ended up creating a page without an associated jcr:content node. This doesn't have to b ...
  • 是肖恩 你是对的,当我设置对keySet()方法的期望时,它被调用。 this.allowing(paramsMap).keySet(); 但我的问题是,我们需要为每一种行为设定期望。 这是否有意义,我的意思是单元测试代码变得超过实际的java代码:)。 我们是否有任何替代解决方案,以便我们可以减少测试代码。 this.allowing(resource).adaptTo(Node.class); this.will(returnValue(node)); ...
  • 您可以使用显示字段并在html属性中指定所需的输出,如下所示。 "warnMsg": { "html": "
    Warning
    ", "xtype": "displayfiel ...
  • 如果通过浏览器从DAM管理页面上传到5.4.0实例,我建议分析它所做的HTTP请求,以便从Flex客户端重现相同的请求。 5.4.0和5.5.0 HTTP API之间可能存在细微差别,这可以解释这一点。 If uploading from the DAM admin page via a browser works on the 5.4.0 instance, I would suggest analysing the HTTP request that this makes, to reproduce t ...

相关文章

更多

最新问答

更多
  • 您如何使用git diff文件,并将其应用于同一存储库的副本的本地分支?(How do you take a git diff file, and apply it to a local branch that is a copy of the same repository?)
  • 将长浮点值剪切为2个小数点并复制到字符数组(Cut Long Float Value to 2 decimal points and copy to Character Array)
  • OctoberCMS侧边栏不呈现(OctoberCMS Sidebar not rendering)
  • 页面加载后对象是否有资格进行垃圾回收?(Are objects eligible for garbage collection after the page loads?)
  • codeigniter中的语言不能按预期工作(language in codeigniter doesn' t work as expected)
  • 在计算机拍照在哪里进入
  • 使用cin.get()从c ++中的输入流中丢弃不需要的字符(Using cin.get() to discard unwanted characters from the input stream in c++)
  • No for循环将在for循环中运行。(No for loop will run inside for loop. Testing for primes)
  • 单页应用程序:页面重新加载(Single Page Application: page reload)
  • 在循环中选择具有相似模式的列名称(Selecting Column Name With Similar Pattern in a Loop)
  • System.StackOverflow错误(System.StackOverflow error)
  • KnockoutJS未在嵌套模板上应用beforeRemove和afterAdd(KnockoutJS not applying beforeRemove and afterAdd on nested templates)
  • 散列包括方法和/或嵌套属性(Hash include methods and/or nested attributes)
  • android - 如何避免使用Samsung RFS文件系统延迟/冻结?(android - how to avoid lag/freezes with Samsung RFS filesystem?)
  • TensorFlow:基于索引列表创建新张量(TensorFlow: Create a new tensor based on list of indices)
  • 企业安全培训的各项内容
  • 错误:RPC失败;(error: RPC failed; curl transfer closed with outstanding read data remaining)
  • C#类名中允许哪些字符?(What characters are allowed in C# class name?)
  • NumPy:将int64值存储在np.array中并使用dtype float64并将其转换回整数是否安全?(NumPy: Is it safe to store an int64 value in an np.array with dtype float64 and later convert it back to integer?)
  • 注销后如何隐藏导航portlet?(How to hide navigation portlet after logout?)
  • 将多个行和可变行移动到列(moving multiple and variable rows to columns)
  • 提交表单时忽略基础href,而不使用Javascript(ignore base href when submitting form, without using Javascript)
  • 对setOnInfoWindowClickListener的意图(Intent on setOnInfoWindowClickListener)
  • Angular $资源不会改变方法(Angular $resource doesn't change method)
  • 在Angular 5中不是一个函数(is not a function in Angular 5)
  • 如何配置Composite C1以将.m和桌面作为同一站点提供服务(How to configure Composite C1 to serve .m and desktop as the same site)
  • 不适用:悬停在悬停时:在元素之前[复制](Don't apply :hover when hovering on :before element [duplicate])
  • 常见的python rpc和cli接口(Common python rpc and cli interface)
  • Mysql DB单个字段匹配多个其他字段(Mysql DB single field matching to multiple other fields)
  • 产品页面上的Magento Up出售对齐问题(Magento Up sell alignment issue on the products page)