DIV CSS 佈局教程網

 DIV+CSS佈局教程網 >> 網頁腳本 >> JavaScript入門知識 >> 關於JavaScript >> Javascript刷新窗口方法小結
Javascript刷新窗口方法小結
編輯:關於JavaScript     

本文實例總結了Javascript刷新窗口方法。分享給大家供大家參考,具體如下:

1.javascript 刷新父窗口

<script>
function reflushParent(){
  window.opener.location.reload();
}
</script>

2.javascript 刷新本窗口

<script>
function reflushMe(){
   javascript:location.reload();
}
</script>

3.javascript 刷新本窗口(新)

<script language='javascript'>
  var currentUrl = this.location.href
  var currentQuery = this.location.search
  window.location.href=currentUrl +currentQuery 
</script>

4.javascript 刷新本窗口並追加一個參數

<script language='javascript'>
  var currentUrl = this.location.href
  var currentQuery = this.location.search
  window.location.href=currentUrl +currentQuery +"&language=English"
</script>

希望本文所述對大家JavaScript程序設計有所幫助。

XML學習教程| jQuery入門知識| AJAX入門| Dreamweaver教程| Fireworks入門知識| SEO技巧| SEO優化集錦|
Copyright © DIV+CSS佈局教程網 All Rights Reserved