35.htm

来自「介绍了javascript的常用的函数」· HTM 代码 · 共 20 行

HTM
20
字号
<html>
<head>
<title>弹出一个居中显示的窗口</title>
</head>
<body>
<script language="javascript">
<!--
	width  = 400;
	height = 300;
		
	windowX = (screen.width - width)/2;
	windowY = (screen.height - height)/2;
	
	features = 	"top=" + windowY + ",left=" + windowX;
	features = features + ",width=" + width + ",height=" + height;
	window.open("pop.htm","",features);
//-->
</script>
</body>
</html>

⌨️ 快捷键说明

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