⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 11-3.htm

📁 javascript 的原代码,是一本书的代码
💻 HTM
字号:
<!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=gb2312">
<title>无标题文档</title>
  <script language="javascript">
      var newWindow ;
	  
	  function newWindow(){
	     if(!newWindow){
		      newWindow = window.open("1-5.html","mywindow","width=200,height=300");
         }else if(newWindow.focus){
		     newWindow.focus();
		 }
		
		 newWindow.location="1-5.htm";
		 newWindow.moveTo(0,0);
		 parent.window.moveTo(250,0);
		 
	  }
	  function writeToWindow(){
	     newWindow.document.open();
		 newWindow.document.focus();
		 var str ="<html><body><center>";
		 str += "AAAAAAAAAAAAAAAAAAAAAAAAAA<br>";
		 str += "BBBBBBBBBBBBBBBBBBBBBBBBBBBb<br>";
		 str += "</center></body></html>";
		 newWindow.document.write(str);
	  }
  </script>
</head>

<body>
  <center>
   <form>
      <input type="button" value="创建窗口" onClick="newWindow()">
	  <input type="button" value="写稳当" onClick="writeToWindow()">
   </form>
   </center>

</body>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -