could tell me front controller in mvc 4 c# visual studio please?
i mean, have big application , want add security restrict access controllers , actions. used in logistic of front controller in codeigniter, adding token session, if wanted write route manually on browser couldnt access.
i've been reading [authorize(roles="admin")] , have admit solution, means have write in every method of controllers, , want have centralized in front-controller if/else.
pd: if don't know how this, @ least try tell me can find front controller in mvc c# visual studio please.
thanks all.
there no such thing front controller in asp mvc. think thing you're looking sort of base controller of other controllers inherit from.
you can add authorize attribute methods or classes (whole controllers). if every action needs attribute suggest create master controller , let every controller inherit controller.
Comments
Post a Comment