摘要:
方式一:使用web.config配置 [HandleError]public class MvcHandleController : Controller { public ActionResult Index() { return View(); } }web.config配置如下<customErrors mode="On" defaultRedirect="~/Account/Error"> <error statusCode="403" redirect="~/404.html"/> 阅读全文