<html>
<head>
<script type="text/javascript">
function openwin() {
 
  window.showModalDialog("page.html",window,"status:no;scroll:no;dialogWidth:235px;dialogHeight:100px");

}

function show(){
 var mes=document.getElementById('textid').value;
 document.getElementById('mesid').innerHTML=mes;

}
</script>
</head>
<body>
<a href="#" οnclick="openwin()">打开一个窗口</a>
<span>
   在这里要对window.open里的参数做一下说明:<br>
   fullscreen=no 窗口模式,yes为全屏模式<br>
   toolbar=no, 显示工具条<br>
  location=no,显示网址栏<br>
  directories=no,导航条<br>
  status=no,状态条<br>
  menubar=no,菜单<br>
  scrollbars=no,滚动条<br>
  resizable=no,是否可以改变大小<br>
  copyhistory=no,历史按钮<br>
  width=350,宽<br>
  height=140'高<br>
  left=200,距离左边200<br>
  top=300,距离顶端300<br>
<span>
 
 <br><br>
 <input type="text" id='textid' name="text1" οnchange="show();"/><br>
 <span id="mesid"></span>
</body>
</html>