I have a multiple choice option menu (I can select multiple elements from the list using command/shift/etc). I want all of the options to be selected as a default (when the page loads). I know that I can use
$(document).ready()
to wait until the page loads to perform an action, but I don't know how to actually change the selected state of the list. Note that there are not checkboxes.
The HTML for the options looks like this:
<select name="name" id="id1">
<option value='value1'>
<option value='value2'>
<option value='value3'>
<option value='value4'>
</select>
Note: I want the changes to be in the javascript rather than the HTML, as I am using a default 'multiple choice menu' template that is consistent across form fields, and I only want the one specific field to have everything selected by default. How can I do this?