How can i make the option of the datalist make me open an another page when i click on it ? | SoloLearn: Learn to code for FREE!

+2

How can i make the option of the datalist make me open an another page when i click on it ?

<input type="search" value="search" placeholder="search.." list="sch"> <datalist id="sch"> <option value="one"> <option value="two"> <option balue="three"> </datalist> Should i use href attribute or another attribute ?

12/23/2019 3:50:11 PM

Mo dix

1 Answer

New Answer

+5

<option value = "main"> <a href="main.html"> Main </a> </option> seems to work, then check through the html validator