javascript n jquery를 처음 사용합니다. jquery 함께 내 스크립트 tag.jquery jquery 함께 추가 한, JavaScript 잘 작동하지만 jquery 함수를 추가 할 때 스크립트가 작동하지 않습니다 ..... JavaScript 또는 둘 다 jquery 변환해야합니다. 또는 내가 anything.Here 말이냐하면 온 클릭이 없을 때 여기에 내가 도시 selected.Its를 기반으로 위치를 로딩하고jquery를 추가 할 때 Javascript가 작동하지 않습니다.
<script type="text/javascript">
function getLocations() {
$.post('@Url.Action("getLocations","Home")', { 'id': $("#cities").val() },
function (data) {
$("#loca").html(data).show();
});
}
$(function() {
$('.submit').on('click', function() {
var ck = "";
var city = $("#cities option:selected").text();
var location = $("#loca option:selected").text();
alert(city+"and"+location)
}
});
</script>
잘 작동 내 스크립트입니다, 그러나 추가 할 때, 위치는로드되지 않습니다 n은 기능이 한테 전화가 .... 내가 모두 작동하려면 다른 어떤 일을 할 필요가 it.Do 내부 경고를 맞대기로 시도하지