JQuery和JQuery mobile出现错误
Errors mixup JQuery and Jquery mobile
JQuery和JQuery mobile有一些问题。当我点击页面中的链接时,我会出现以下错误:
未捕获错误:无法在初始化之前调用页面上的方法;试图调用方法"bindRemove"
我试图改变链接rel和脚本的位置,但它破坏了我的设计。。。
有人有主意吗?
这是我的代码:
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<!-- Include meta tag to ensure proper rendering and touch zooming -->
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Accueil</title>
<!-- CSS -->
<!-- Include jQuery Mobile stylesheets -->
<link rel="stylesheet" href="http://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.min.css">
<!-- CSS splashscreen -->
<link rel="stylesheet" type="text/css" href="css/wemind/splashscreen.css" />
<link rel="stylesheet" type="text/css" href="css/wemind/styles_wemind.css" />
<!-- JS -->
<!-- Include the jQuery library -->
<script src="http://code.jquery.com/jquery-1.11.2.min.js"></script>
<!-- Include the jQuery Mobile library -->
<script src="http://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.min.js"></script>
<!-- Scripts splashscreen -->
<script src="js/jquery.splashscreen.js"></script>
<script src="js/script_splashscreen.js"></script>
</head>
<body>
<div id="promoIMG" />
<div data-role="page" id="main-page">
<div id="actionbar-main"><img src="img/ic_launcher.png" /></div>
<p class="text-accueil">Qui êtes-vous ?</p>
<div id="student-link"><a href="login.php" data-transition="slide"><img src="img/ic_student.png" /></a></div>
<p class="wemind-font">Student</p>
<div id="horiz-sep-main"><img src="img/ic_sep.png" /></div>
<div id="parent-link"><a href="login.php" data-transition="slide"><img src="img/ic_teacher.png" /></a></div>
<p class="wemind-font">Teacher</p>
</div>
提前感谢
js/
脚本中的某些内容试图在初始化Mobile小部件之前对其进行操作。查找使用bindRemove作为参数的任何函数,并在不带任何参数的情况下调用它,以便在调用bindRemove之前初始化其小部件。
我试过这个:
<script>
$( document ).ready(function() {
$( "a" ).click(function( event ) {
window.location = $(this).attr("href");
});
});
</script>
我把这个放在但当我注销时,我被重定向到此页面,问题再次出现。。。我应该可以毫无问题地点击链接,用这么简单的代码很奇怪!
相关文章:
- 将菜单项与滚动绑定时出现Jquery错误
- 试图获取表单时出现Jquery错误
- 任何人都知道IE7设置或更新/补丁,它可以防止IE因为jquery错误而无法加载页面
- 组中需要Jquery错误位置
- IE9中的Jquery错误
- 使用下拉菜单排除jquery错误
- 在文本区域检查电子邮件数据时出现奇怪的jquery错误
- 扩展对象导致jQuery错误
- 一个经典的jQuery错误 - 未捕获的类型错误:未定义不是一个函数
- 使用ng-include时发生Angular.js jQuery错误
- JQuery 错误 -- 减慢在浏览器中查看错误的操作速度
- 在页面上获取网格数据之前出现 jQuery 错误
- 如何修复我的 JQuery 错误
- jQuery 错误 SCRIPT5002:IE9 64 位中预期的函数
- jQuery错误地导致悬停
- 未定义获取 jquery 错误 $
- 将 jQuery 错误处理添加到列表、网格内的 JSF 页面上的所有图像
- 未捕获的错误:信号器 jquery 错误
- JQuery 错误的脚本顺序
- 当展开点击 li 的 ul 事件时,JS JQUERY 错误不起作用