【问题标题】:Jquery Validation Remote JSON not working with Jquery MobileJquery Validation Remote JSON 不适用于 Jquery Mobile
【发布时间】:2012-09-27 04:28:51
【问题描述】:

我搜索了这个网站和其他网站,试图找到我的问题的答案。我正在使用 jQuery Mobile 1.1.1、jQuery 1.7.2、jQuery Validation 1.9。和一个返回布尔值的 JSON 服务。

下面的远程调用在任何计算机浏览器中都很好用,但在移动浏览器中不起作用。

remote: {
    url:'https://myjsonservice/check.json',
    type:"POST",
    dataType:'jsonp',
    dataFilter:function(data) {
        if( data == "true" ) {return success;}
    }
},

关于如何在移动浏览器上使用此功能有什么想法吗?

【问题讨论】:

    标签: jquery json jquery-mobile jquery-validate


    【解决方案1】:

    遇到了这个问题,但从未得到答复。

    您应该尝试使用常规 JSON。如果您的 Web 服务在另一个域上,只需创建一个同域代理。

    如果您不想这样做,请尝试:JSONP calls not working with apple-mobile-web-app-capable="yes"

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2012-10-07
      • 2018-03-12
      • 1970-01-01
      • 1970-01-01
      • 2020-11-18
      • 2013-08-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多