Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

how to add options to select in jquery array

$.each(selectValues, function(key, value) {   
     $('#mySelect')
         .append($("<option></option>")
                    .attr("value", key)
                    .text(value)); 
});
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #add #options #select #jquery #array
ADD COMMENT
Topic
Name
6+2 =