jQuery select 주무르기

jQuery로 선택된 값 읽기 [code language=”javascript”] $(“#selectBox option:selected”).val(); $(“#select_box > option:selected”).val(); $(“select[name=name]”).val(); $(“selectBox”).val(); -> 요것도 나옵니다. [/code] jQuery로 선택된 내용 읽기 $(“#selectBox option:selected”).text(); 선택된 위치 var index = $(“#test option”).index($(“#test option:selected”)); // Add options to the end of a select, 맨 뒤에 추가 $(“#selectBox”).append(“<option value=’1′>Apples</option>”); $(“#selectBox”).append(“<option value=’2′>After Apples</option>”); // Add options to the start of […]