注册 登录
编程论坛 ASP.NET技术论坛

js打开超链接

zh520 发布于 2008-03-13 20:37, 829 次点击
<html>
<input type="text" id="txt" />
<a href="#" onclick="javascript:window.open(document.getElementById('txt').value)">打开
</a>
</html>
我想打开输入到文本框中的链接地址,这样写不行,哪为大哥帮帮忙啊
3 回复
#2
1916381412008-03-13 21:27
这样改
onclick="javascript:window.open('document.getElementById('txt').value');")
#3
zh5202008-03-14 10:13
提示: 作者被禁止或删除 内容自动屏蔽,只有管理员可见
#4
wyg48592008-03-14 16:42
...........
1