asp.net mvc - Get Http Status Code and Status Description in Custom Error Page -


where set http status code , http status description in "handleunauthorizedrequest" method of custom authorizeattribute, can in error page. have error pages different status codes.

example: if user not authorized access resource, setting http status code 403 , description says permissions needed access resource. hence, when user redirect 403 custom error page, can show description.

is there way set except in tempdate or viewdata?

i want same in custom authorize attribute of web api.


Comments

Popular posts from this blog

javascript - Confirm a form & display message if form is valid with JQuery -

Retrieving ETA (estimated time of arrival) with Google Distance Matrix API and public transit as transport mode -

ionic framework - Meteor - Error: Failed to execute 'insertBefore' on 'Node' -