i cant made input type enable or disable. when i select drop down value then onpe input field enable and other disable[upl-image-preview url=https://www.webdeveloper.com/assets/files/2019-11-21/1574314807-616151-pblm.png]
<select id="select1"> <option>opt 1</option> <option>opt 2</option> <option>opt 3</option> <option>opt 4</option> <option>opt 5</option> <option>opt 6</option> </select> <input id="input1"> <input id="input2"> <input id="input3"> <script> var inp1 = document.getElementById('input1'), inp2 = document.getElementById('input2'), inp3 = document.getElementById('input3'); document.getElementById('select1').addEventListener('change', function () { if (this.selectedIndex == 3) { inp2.disabled = true; inp3.disabled = false; } else { inp2.disabled = false; inp3.disabled = true; } }); </script>
Help @hasib2020 spread the word by sharing this article on Twitter...