jQuery请求未定义的url(与phpdevshell一起使用)

编程入门 行业动态 更新时间:2024-10-27 16:37:05
本文介绍了jQuery请求未定义的url(与phpdevshell一起使用)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我正在使用phpdevshell(使用最新的jQuery)创建一个应用程序。

I'm creating an app using phpdevshell (which uses latest jQuery).

现在我没有任何理由可以看到,jQuery开始请求以undefined结尾的url 这不存在并导致404.

Now without any reason visible to me, jQuery started requesting an url ending with "undefined" which doesn't exist and causes 404.

它寻找这个网址: http:// localhost / mysite / undefined

我找到了执行此操作的jQuery部分(从第7866行开始):

I've located the part of jQuery that does this (starting at line 7866):

// Do send the request // This may raise an exception which is actually // handled in jQuery.ajax (so no try/catch here) xhr.send( ( s.hasContent && s.data ) || null );

知道为什么会这样吗?谢谢。

Any idea why this happens? Thanks.

推荐答案

看起来你正在构建一个带有返回undefined的变量的url。即:var url = http:// localhost / mysite / +变量;变量未定义的地方。

It looks like you're building an url with a variable that returns undefined. Ie: var url = " localhost/mysite/" + variable; where variable is undefined.

更多推荐

jQuery请求未定义的url(与phpdevshell一起使用)

本文发布于:2023-08-04 01:27:15,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1291672.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:未定义   jQuery   phpdevshell   url

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!