Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/jquery/76.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
jQuery移动预取页面自动_Jquery_Mobile_Prefetch - Fatal编程技术网

jQuery移动预取页面自动

jQuery移动预取页面自动,jquery,mobile,prefetch,Jquery,Mobile,Prefetch,我需要向我的JQM项目添加一个预加载页面。我认为最好的方法是在预加载页面上使用JQM Prefetch函数,并在预取主页加载后启动它 这是我使用的代码。我不知道在哪里添加urlhome.html,是否需要添加一个实例才能使其正常工作?任何帮助都将不胜感激。多谢各位 HTML <head> <script src="js/jquery-1.7.1.min.js"></script> <script src="js/custom.js"></sc

我需要向我的JQM项目添加一个预加载页面。我认为最好的方法是在预加载页面上使用JQM Prefetch函数,并在预取主页加载后启动它

这是我使用的代码。我不知道在哪里添加urlhome.html,是否需要添加一个实例才能使其正常工作?任何帮助都将不胜感激。多谢各位

HTML

<head>
<script src="js/jquery-1.7.1.min.js"></script>
<script src="js/custom.js"></script>
<script src="js/jquery.mobile-1.2.0-rc.1.min.js"></script>
</head>
$(document).bind("mobileinit", function(){
$.mobile.loadPage( pageUrl, { showLoadMsg: false } );
});