Tryit Editor v2.3

Edit This Code:
<!DOCTYPE html> <html> <head> <script> function selectMultiple() { document.getElementById("mySelect").multiple = true; } </script> </head> <body> <form> <select id="mySelect" size="4"> <option>Apple</option> <option>Pear</option> <option>Banana</option> <option>Orange</option> </select> <input type="button" onclick="selectMultiple()" value="Select multiple"> </form> <p>Before you click "Select multiple", you cannot select more than one option (by holding down the Shift or Ctrl key).</p> <p>After you have clicked "Select multiple", you can.</p> </body> <!-- Mirrored from www.w3schools.com/js/tryit.asp?filename=try_dom_select_multiple by HTTrack Website Copier/3.x [XR&CO'2014], Fri, 23 Jan 2015 07:36:54 GMT --> </html>
Result:
Try it Yourself - © w3schools.com