我有一個html頁面「form1.html」,它有一個動畫圖像。我想在5秒後加載另一個頁面「form2.html」。我該怎麼做呢?我想在特定的時間量後載入另一個HTML頁面
53
A
回答
49
<script>setTimeout(function(){window.location.href='form2.html'},5000);</script>
而對於主頁只添加 '/'
<script>setTimeout(function(){window.location.href="/"},3000);</script>
16
<meta http-equiv="refresh" content="5;URL='form2.html'">
13
利用這段JavaScript代碼:
<script>
setTimeout(function(){
window.location.href = 'form2.html';
}, 5000);
</script>
+1
'TimeOut' =>'Timeout' –
0
使用JavaScript的setTimeout的:
<body onload="setTimeout(function(){window.location = 'form2.html';}, 5000)">
相關問題
- 1. 在特定時間間隔後提交一個jsp頁面
- 2. 另一個html頁面的javascript變量
- 3. 在幾個日期和特定的時間間隔從一個網頁重定向到另一個頁面
- 4. 如何在特定頁面加載時間後顯示Div?
- 5. 從javascript加載另一個html頁面
- 6. HTML頁面加載時間
- 7. 通過從不同的html頁面調用,在另一個html頁面的div中加載一個html頁面
- 8. 想要在客戶端包含一個html頁面到另一個頁面
- 9. 載入頁面內的另一個
- 10. 我想在HTML頁面
- 11. 想要在另一個頁面回顯一個php變量
- 12. 滑動html頁面如果我水平滑動,加載另一個html頁面
- 13. Django:我想根據從另一個頁面獲得的特定用戶標識獲得一個頁面
- 14. 我想從另一個頁面加載時清除頁面的cookie但不是在重新加載同一頁面時刪除頁面的Cookie
- 15. 嵌入HTML頁面到另一個
- 16. 強制重新加載一小段時間後的html頁面
- 17. 加載一個特定的PHP頁面
- 18. 加載另一個頁面需要很長時間jquery加載
- 19. 我想在頁面上刮一個特定的ID與一個ID
- 20. 在運行另一個頁面時刷新HTML PHP頁面?
- 21. 我想當前頁面的id重定向到另一頁ID
- 22. 另一個HTML頁面?
- 23. 將特定頁面重定向到iis web.config中的另一個特定頁面
- 24. 在特定時間重定向頁面
- 25. 將特定字段鏈接到另一個html頁面
- 26. 我想重定向到另一個頁面使用角度JS
- 27. 我想中心在我的頁面中間的文本HTML
- 28. 爲什麼當我想加載另一個頁面時,Page_Load事件觸發?
- 29. 我可以傳遞一個變量從一個HTML頁面到另一個HTML頁面使用PHP?
- 30. 我想將一個輸入變量傳遞給另一個頁面,但它帶給我一個錯誤
爲什麼在問題標題超出jQuery主題時標記jQuery問題的重複? –
看看讓你的第三頁的問題,看起來像的http://stackoverflow.com/questions/503093/how-can-i-make-a-page-redirect-using-jquery/25537534#25537534 –
^聰明的方式接受的答案,其中有8800 upvotes。 – coreyward