打开链接后的空白页面。我需要刷新才能看到内容

时间:2015-08-13 10:49:15

标签: jquery html5

所以我有一些链接的HTML页面。

让我们说:1。index.html链接到page1.html和page1链接到page2.html

这是我的index.html和page1.html

中的标题
    <script src="http://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js"></script>        
    <script src="http://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.min.js"></script>  
    <link rel="stylesheet" href="http://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.min.css"/> 
    <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/js/bootstrap.min.js"></script>  
    <script src="js/jquery-ui.min.js"></script>
    <script src="js/date.js"></script>      
    <script src="js/leslider.js" type="text/javascript"></script>
    <link rel="stylesheet" href="http://dev.jtsage.com/cdn/datebox/latest/jqm-datebox.min.css" />    
    <script src="http://dev.jtsage.com/cdn/datebox/latest/jqm-datebox.core.min.js"></script>       
    <script type="text/javascript" src="http://dev.jtsage.com/cdn/datebox/latest/jqm-datebox.mode.flipbox.min.js"></script>
    <link rel='stylesheet prefetch' href='http://photoswipe.s3.amazonaws.com/pswp/dist/photoswipe.css'>
    <link rel='stylesheet prefetch' href='http://photoswipe.s3.amazonaws.com/pswp/dist/default-skin/default-skin.css'>
    <script src='http://photoswipe.s3-eu-west-1.amazonaws.com/pswp/dist/photoswipe.min.js'></script>
    <script src='http://photoswipe.s3-eu-west-1.amazonaws.com/pswp/dist/photoswipe-ui-default.min.js'></script>

这是我的page2.html标题

    <link rel='stylesheet prefetch' href='http://photoswipe.s3.amazonaws.com/pswp/dist/photoswipe.css'>
    <link rel='stylesheet prefetch' href='http://photoswipe.s3.amazonaws.com/pswp/dist/default-skin/default-skin.css'>
    <script src='http://photoswipe.s3-eu-west-1.amazonaws.com/pswp/dist/photoswipe.min.js'></script>
    <script src='http://photoswipe.s3-eu-west-1.amazonaws.com/pswp/dist/photoswipe-ui-default.min.js'></script>
    <link rel="stylesheet" type="text/css" href="../index.css" /> 

我正在使用JQ和JQM以及一些插件和脚本;但是我不知道,为什么在我点击从page1.html到page2.html的grom链接后,页面应该保持白色,直到我手动刷新它。

另外,如果我不刷新页面,我可以回去(F5),但是如果我刷新页面,它甚至不会回到之前的文档。

1 个答案:

答案 0 :(得分:0)

我在某处读过,(我不记得在哪里 - 我会更新,如果我这样做)只是在正文中加载脚本(在未加载的页面上),并且实际上是有效的。