DIV CSS 佈局教程網

 DIV+CSS佈局教程網 >> 網頁腳本 >> JavaScript入門知識 >> 關於JavaScript >> js中window.open打開一個新的頁面
js中window.open打開一個新的頁面
編輯:關於JavaScript     
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> 
<html> 
<head> 
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> 
<title>Insert title here</title> 
<script type="text/javascript"> 
/* 打開同一個新的頁面,不會再次打開新頁面 */ 
function open1(){ 
  window.open("html01.html","aaa"); 
} 
function open2(){ 
  window.open("html02.html","aaa"); 
} 
</script> 
</head> 
<body> 
  <a href="#" rel="external nofollow" rel="external nofollow" onclick="open1()">點擊進入1</a> 
  <a href="#" rel="external nofollow" rel="external nofollow" onclick="open2()">點擊進入2</a> 
</body> 
</html>
XML學習教程| jQuery入門知識| AJAX入門| Dreamweaver教程| Fireworks入門知識| SEO技巧| SEO優化集錦|
Copyright © DIV+CSS佈局教程網 All Rights Reserved