Akki. Nikam

Akki. Nikam

  • NA
  • 48
  • 5.2k

Jquery script for Edit view for cascading dropdown in mvc

Feb 6 2018 2:01 AM
<script>
$(document).ready(function () {
$("#Country").change(function () {
$.get("/Home/State_Bind", { CntId: $("#Country").val() }, function (data) {
$("#State").empty();
$.each(data, function (index, row) {
$("#State").append("<option value='" + row.stId + "'>" + row.State1 + "</option>")
})
})
})
$("#State").change(function () {
$.get("/Home/City_Bind", { stId: $("#State").val() }, function (data) {
$("#District").empty();
$.each(data, function (index, row) {
$("#District").append("<option value='" + row.ctId + "'>" + row.City1 + "</option>")
})
})
})
});
</script>
what changes have to be made for Edit dropdown 
 
 
 

Answers (6)