Drop down menu 我正在寻找一个示例javascript,如果dropdownlist selected value=一个特定值,它将显示不同的隐藏输入。有人有什么吗?
我应该从什么代码开始?我知道onChange无法处理input=hidden。是否最好编写一些东西来重新命名隐藏字段,然后将其构建到现有的onchange下拉列表中?无法100%确定您想要做什么。我不相信用Thank做标记是可能的,我把on change全部设置为go,并且能够让它发送变量隐藏字段,问题是命名/值标题冲突,getElementByIdvalue绕过了某些值并从其他位置将它们拉出来。我还是个新手Drop down menu 我正在寻找一个示例javascript,如果dropdownlist selected value=一个特定值,它将显示不同的隐藏输入。有人有什么吗?,drop-down-menu,input,onchange,hidden-field,Drop Down Menu,Input,Onchange,Hidden Field,我应该从什么代码开始?我知道onChange无法处理input=hidden。是否最好编写一些东西来重新命名隐藏字段,然后将其构建到现有的onchange下拉列表中?无法100%确定您想要做什么。我不相信用Thank做标记是可能的,我把on change全部设置为go,并且能够让它发送变量隐藏字段,问题是命名/值标题冲突,getElementByIdvalue绕过了某些值并从其他位置将它们拉出来。我还是个新手 <input type="hidden" value="OK"> <
<input type="hidden" value="OK">
<p id="demo">Click the button below to set the type attribute of the button above.</p>
<button onclick="myFunction()">Try it</button>
<script type="text/javascript">
function myFunction()
{
document.getElementsByTagName("INPUT")[0].setAttribute("type","button");
};
</script>
<p>Internet Explorer 8 and earlier does not support the setAttribute method.</p>