============================
假設部分檢視的路徑為~/Manager/Student/3,且一開始就載入部分檢視,只要在script中定義function:
jQuery(document).ready(function () {
ajax_updatePartial('<%= Url.Content("~/Manager/Student/")%>' + '<%: Model.Id %>');
});
function ajax_updatePartial(path){
$.ajax ({
url: path,
success: function(result) {
$('#AjaxStudentInClassPartial').html(result);
}
});
return false;
}
沒有留言:
張貼留言