For this dropdownlist in HTML:
<select id='countries'> <option value='1'>Country</option> </select>
I would like to open the list (the same as left-clicking on it). Is this possible using JavaScript (or more specifically jQuery)?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You can easily simulate a click on an element, but a click on a
<select>won’t open up the dropdown.Using multiple selects can be problematic. Perhaps you should consider radio buttons inside a container element which you can expand and contract as needed.