WebForms UnobtrusiveValidationMode 需要“jquery”ScriptResourceMapping
在进行牛腩新闻发布系统时,遇到如下错误:
解决办法:
在webconfig中找到
<appSettings>
<add key=" aspnet:UseTaskFriendlySynchronizationContext" value="true" />
<add key="ValidationSettings:UnobtrusiveValidationMode" value="WebForms" />
</appSettings>
删除<add key="ValidationSettings:UnobtrusiveValidationMode" value="WebForms" />即可。
如果没有上面两句话,在webconfig中添加以下内容即可:
<appSettings>
<add key="ValidationSettings:UnobtrusiveValidationMode" value="None"/>
</appSettings>
重新刷新界面,问题解决~