在cshtml中
<form action="/Sp/EditSp" method="post" onclick="Sys.Mvc.AsyncForm.handleClick(this, new Sys.UI.DomEvent(event));" onsubmit="Sys.Mvc.AsyncForm.handleSubmit(this, new Sys.UI.DomEvent(event), { insertionMode: Sys.Mvc.InsertionMode.replace, httpMethod: 'POST', updateTargetId: 'divDisplay', onSuccess: Function.createDelegate(this, deactivateAList) });"><input type="hidden" id="requestSequence" name="requestSequence" value="24" />
的javascript:
`
<script type="text/javascript">
function deactivateAList() {
document.getElementById("AList").style.display = "none";
}
</script>
`
请告诉我如何解决此错误。
答案 0 :(得分:5)
我已添加:
<add key="UnobtrusiveJavaScriptEnabled" value="true" />