Reputation: 1287
I have a drop down menu on a remote page whose source i can only view/copy but cannot edit it , so i am attempting to reconstruct the page from the source code of the currently existing one. I want to select all options from the menu when so i can view all the records the values hold at once. How can this be done? Also even if any answers provided will only allow me to edit it, i will do my best to power through. I saw another question where the user was given some jQuery code to include. My question is how can I do this?
This is the javascript for the page http://pastebin.com/Hv63diFH This is a snippet of the code as how it appears:
<option value="5102">Company 1</option>
<option value="5053">Company 2</option>
<option value="5091">Company 3</option>
<input type="submit" value="Search">
<br>
<INPUT TYPE="text" NAME="input1" size="50" VALUE="" ONKEYUP="autoComplete(this,this.form.select_business,'text',true)">
</form>
Upvotes: 0
Views: 3069
Reputation: 81
To select multiple options in dropdown, set the attribute "multiple" to "multiple" for that dropdown.
Eg : <select multiple="multiple">
<option>A</option>
<select>
Upvotes: 1
Reputation: 13080
As far as I am aware in HTML you cannot select multiple options from a select box at once.
You need to create something that appears like a drop down box which allows for multiple selection. Which will require some JavaScript coding.
You could either list a load of check boxes and select those which would allow for submission of the form in the natural manner via HTML. Or you could post whatever information you collect from JavaScript (if you went for example with a list of anchor elements with specific ids to define criteria).
You could also add an additional feature which is a select all link... and well... does what it says basically.
Upvotes: 0