在HTML实现: 有一个下拉框, 与一个"铵钮", 选择下拉框, 然后按"铵钮", 打开下拉框连接
在HTML实现: 有一个下拉框, 与一个"铵钮", 选择下拉框, 然后按"铵钮", 打开下拉框value='file1.htm' 的连接
在HTML实现: 有一个下拉框, 与一个"铵钮", 选择下拉框, 然后按"铵钮", 打开下拉框value='file1.htm' 的连接
答案:<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=gb2312" /> <title>无标题文档</title> </head> <body> <select name="lstURL" size="1" id="lstURL"> <option value="http://www.zzzyk.com">打开baidu</option> <option value="http://www.google.cn">打开google</option> </select> <input type="button" name="Submit" value="GO" onclick="window.location.href=lstURL.value"/> </body> </html>
其他:function aaa() {
var a = document.getElementById("a");
window.location.href = a.value;
}
<select id="a">
<option value="file1.htm">111</option>
</select>
<input type="button" id="btn" onclick="aaa()"/>
上一个:matlab出现错误说"could not load html.....",怎么回事
下一个:RewriteRule (.*\.html)$ /index.php 什么意思