例如:
<input type="text" name="hello" id="hello"/>&&你好
<a href="#" onclick="onformopen('')">Email</a>
<script language="javascript">
function onformopen(){
var hello = document.getElementById("hello").value;
var other = document.getElementById("other").value;
var url = "hello.html?other="+other+"&hello="+hello;
atenaKensakuWin = window.open(url);
}
</script> 我需要传的不只这2个 而且只能用这种办法解决问题 (我自己也很讨厌这需求)哪个哥哥 帮帮我啊 要怎么做 才能把&这个字符处理成地址不理解的关键字啊
<input type="text" name="hello" id="hello"/>&&你好
<a href="#" onclick="onformopen('')">Email</a>
<script language="javascript">
function onformopen(){
var hello = document.getElementById("hello").value;
var other = document.getElementById("other").value;
var url = "hello.html?other="+other+"&hello="+hello;
atenaKensakuWin = window.open(url);
}
</script> 我需要传的不只这2个 而且只能用这种办法解决问题 (我自己也很讨厌这需求)哪个哥哥 帮帮我啊 要怎么做 才能把&这个字符处理成地址不理解的关键字啊
解决方案 »
- 拾色器部分代码的疑问:)
- js文档解析一个解决方法
- 随机获取图片 JAVASCRIPT
- js字符串判断是否追加?
- 想问一下怎么在打开页面时自动弹出加入收藏的提示?
- 紧急求教:java script代码段该放页面中哪个位置才正确?
- 在看一个HTML的在线编辑器,是和ASP结合的,请各位帮忙解释一下这个句子的意思?不懂啊
- 写一个js脚本,检查checkbox中是否已经有选中的,没选则弹出对话框,在等待。。。。。
- 哪位牛人知道如何在打开的模态窗口中访问打开它的父窗口的window对象
- 如何更新同一个FrameSet中另一个Frame的内容
- 父js 访问 子js 的函数
- 怎么让一个窗品按F11的效果全屏显示, 注意是没有标题栏的那种
var url = "hello.html?other="+escape(other)+"&hello="+escape(hello);
var url = "hello.html?other="+other+"&hello="+hello;
<form name="form1" method="get" action="hello.html" target="_blank">
<input type="text" name="hello">
</form>
没有显示的参数用hidden
调用document.form1.submit();方法二:
用escape()之类的js方法对value编码
在hello.html中再用unescape()解码