asp.net - .NET ASP webpage inheritance -
i new .net , ideally want make several layers of abstraction making complex website. being first layer handling login, authentication, etc, layer handling built in apps (how look, predefined functions, database connections), , lower level specific app implementation details.
this favors uniformity apps inherit 1 place allowing easier maintenance , rapid development of smaller apps once overhead abstraction layers handle responsibilities.
the problem not 100% sure start .net asp webpage inheritance. tried google , searching may not looking right thing. hoping experience on matter may direct me towards resources make kind of webpage inheritance/abstraction easier!
i using visual studio 2010.
edit: want add purpose question: individual creating base of website handle authentication, portal, ui look, etc
i want make app base uses website framework , adds onto standards every app must meet, function library, addition ui overrides not applicable portal, etc.
from there third layer directly inherit above app base framework (abstraction) , further specify based on guide lines made.
i appreciate feedback far!
in asp.net have 4 common ways reuse code/abstractions serve application-wide
- the first way using base page, inherit standard asp.net page , share common logic of pages, explained here
- the second way using master page: master page defines common design (html / css - wise) pages use throughout application. can accessed programmatically pages use it, , therefore share common logic
- the third way using http module: http module class, responsible handling http request before handled expected pages code on server, , allows add common logic want application use (such authentication / authorization handling, getting relevant user information db, etc)
- global.asax: contains application/session wide event handlers, allow handle events in once place (everything application starting user session ending)
using modules , base page preferred way, if want build few applications, sharing common behaviour. master page can used well, of course, if want them share same design well.
Comments
Post a Comment