-

- 加为好友
- 发送私信
- 在线聊天
jimu8130
- 等级:

- 可用分等级:
- 总技术分:
- 总技术分排名:
|
| 发表于:2008-10-28 16:17:4717楼 得分:0 |
汗这个有点bt的做法啊,通常都是一次多选然后返回,如果是你这样的o想到一个实现办法就是发起会议页面设定一个js函数每隔1秒或一段时间读取一下特定cookie(存放你选择的人员的资料和是否需要读取标志两个cookie)这个当点击发起会议按钮触发这个函数,当人员选择页面关闭的时候对是否需要读取的cookie设定不读取,并且每次选择人员,都用js来将已经选择的所有人员的信息遍历组合存储到人员资料的cookie中 不过你还可以考虑这个在子页面对父页面的控件的值进行更改,不过我没实践 JavaScript实际应用:父子页面交互 1。父窗口传递信息给子窗口 看代码实例: <script language=javascript> function outPut() { //获取父窗口的文本信息赋值给text var text = document.abc.text.value; //打开子窗口,并且把操作句柄赋值给win变量,以下所有操作都是针对win对象的 var win = window.open("","mywin", "menubar=no,width=400,height=100,resizeable=yes"); //输出基本信息 win.document.writeln(" <title>输出结果 </title>"); win.document.writeln("你的信息是: <p>"); //输出从父窗口获取的信息 win.document.writeln(text); win.document.close(); win.focus(); } </script> <form name=abc method=post> <input type=text name=text size=50> //调用上面的函数 <input type=button value=提交 onClick="outPut()"> </form> 2。子窗口传递参数给父窗口 我们对上面的代码进行改造: <script language=javascript> function outPut() { var text = document.abc.text.value; var win = window.open("","mywin", "menubar=no,width=400,height=100,resizeable=yes"); win.document.writeln(" <title>输出结果 </title>"); win.document.writeln("你的信息是: <p>"); win.document.writeln(text); win.document.writeln(" <input type=text name=child value=子窗口信息>"); //对子窗口本身操作,使用self对象,对父窗口操作使用opener对象,这是关键 //把子窗口中表单的值回传给父窗口,取代父窗口表单以前的值,然后关闭子窗口 win.document.writeln(" <input type=button value=关闭自己 onClick='window.opener.abc.text.value=self.child.value;self.close()'>"); //可以控制关闭父窗口 win.document.writeln(" <input type=button value=关闭父窗口 onClick='window.opener.opener=null;window.opener.close()'>"); //刷新父窗口 win.document.writeln(" <input type=button value=刷新父窗口 onClick='window.opener.location.reload()'>"); win.document.close(); win.focus(); } </script> <form name=abc method=post> <input type=text name=text size=50> <input type=button value=提交 onClick="outPut()"> </form> | | |
修改
删除
举报
引用
回复
| |