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

Command prompt result in label. Python 2.7 -

javascript - How do I use URL parameters to change link href on page? -

amazon web services - AWS Route53 Trying To Get Site To Resolve To www -