blockui 需要 jquery v1.2.3 或更高版本您正在使用 v.1.11.1
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/23626504/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
blockui requires jquery v1.2.3 or later you are using v.1.11.1
提问by Dwza
Acually im using a higher version.
实际上,我正在使用更高版本。
The error what is called is (Alert)
所谓的错误是(警报)
blockui requires jquery v1.2.3 or later you are using v.1.11.1
im not using wordpress or any other kind of programms/applications like this...
我没有使用 wordpress 或任何其他类型的程序/应用程序...
so solutions for wordpress won't help. i have a private project using jquery and jquery ui...
所以wordpress的解决方案无济于事。我有一个使用 jquery 和 jquery ui 的私人项目...
anyone knows the issue and how to fix this issue ?
任何人都知道这个问题以及如何解决这个问题?
回答by Dwza
I found the issue!
我发现了问题!
Here is a Fix for all who have the same problem
这是所有遇到相同问题的人的修复程序
jquery.blockUI.js
jquery.blockUI.js
// Old if condition
//if (/1\.(0|1|2)\.(0|1|2)/.test($.fn.jquery) || /^1.1/.test($.fn.jquery)) {
//new if condition
if ((/1\.(2\.([3-9]|[1-9][0-9])|[3-9]\.[0-9]*|[1-9][0-9]*\.[0-9]*)/.test($.fn.jquery)) === false ) {
total condition looks like
总状况看起来像
if ((/1\.(2\.([3-9]|[1-9][0-9])|[3-9]\.[0-9]*|[1-9][0-9]*\.[0-9]*)/.test($.fn.jquery)) === false ) {
alert('blockUI requires jQuery v1.2.3 or later! You are using v' + $.fn.jquery);
return;
}
this will check the version from 1.2.3up to 1.99~.99~.
这将检查从1.2.3到1.99~.99~ 的版本。
guess there will be a couple of years to reach this :D
估计需要几年时间才能达到这个目标:D
回答by Zsolti
回答by Nizar B.
Just get rid and delete this version check-up.
只需摆脱并删除此版本检查即可。
Remove this part from the blockui.js file:
从 blockui.js 文件中删除这部分:
if (/1\.(0|1|2)\.(0|1|2)/.test($.fn.jquery) || /^1.1/.test($.fn.jquery)) {
alert('blockUI requires jQuery v1.2.3 or later! You are using v', [$.fn.jquery]);
return;
}
}