易截截图软件、单文件、免安装、纯绿色、仅160KB

Javascript实现子窗口向父窗口传值(转)

page1.html为父窗口,page2.htm为子窗口。详细代码如下: 
page1.html 
引用
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> 
<html> 
<head> 
  <meta http-equiv="Content-Type" content="text/html; charset=GB2312" /> 
  <title>子窗口传值给父窗口</title> 
  <script language="JavaScript" type="text/javascript"> 
    function openWin(u, w, h) { 
              var l = (screen.width - w) / 2; 
              var t = (screen.height - h) / 2; 
               var s = 'width=' + w + ', height=' + h + ', top=' + t + ', left=' + l; 
                  s += ', toolbar=no, scrollbars=no, menubar=no, location=no, resizable=no'; 
               open(u, 'oWin', s); 
       } 
   function openIt(){ 
    window.open("page2.html",400,300); 
   } 
  </script> 
</head> 
<body> 
  <input type="text" id="text1" /> 
  <input type="button" value="弹出" onclick="openIt()" /> 
</body>


相关文档:

javascript写类方式之十

10、mootools.js的写类方式
mootools.js的最新版本是1.2.3,这里使用的是1.2.0。mootool被设计成非常紧凑的,模块化的,面向对象的的js库。mootool中写类用Class类。Class类由Native类new出来的:
/*
*Script: Class.js
*/
var Class = new Native({
name: 'Class',
initialize: function(properties){
propert ......

JSL (JavaScript Loader)

Do you want an ultra fast web site? Get JSL and optimize your JavaScript loading now!
Imagine there's a 4-lane highway between your web browser and the internet itself. This highway is optimize to let pictures, text, and css fly by. But, when it comes to external scripts, the highway crea ......

JavaScript操作服务器控件之Gridview控件

JavaScript操作服务器控件之Gridview控件
1.JavaScript脚本如下:
<script language="javascript" type="text/javascript">
    function gridviewControl()
    {
        //获取GridView的客户端元素
       ......

javascript定时更换表格背景

<html>
<head>
<title>changePage</title>
</head>
<body>
<table id="pic" cellpadding="0" cellspacing="0" border="1" width="200" height="100" bordercolor="red">
<tr>
<td>picture chanage!</td>
</tr>
</table>
< ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号