2
Coffeescript를 통해 국가 드롭 다운이 "캐나다"또는 "미국"인 경우 주 /도 필드를 표시하려고합니다.커피점 드롭 다운 값
지금까지 내가 가진 (그러나 복잡한 통해 보인다) 당신은, 그러나
selected = $('#order_shipping_address_attributes_country option:selected').text()
을 할 수 http://api.jquery.com/selected-selector/에 따라 상황이 더 나은와
selected = $('#order_shipping_address_attributes_country option')
.filter(':selected').text()
jQuery에 따라 권장되는 방법을 지적 해 주셔서 감사합니다. 나는 그것의 일부를 사용하는 것을 끝내었다. – olimart