asp.net - Generating a Webpage When It doesn't Exist -
how can generate webpage based on users request? example, if wants visit "www.mywebsite.com/example" , there no such url, website generate him/her webpage based on word "example". how can it? (i'm developing website asp.net)
one way process such page use asp.net attribute routing.
[route("{pagename}")] public actionresults myactionname(string pagename) { // in action method process need // figure out need generate base push user. //------ // either make generic view , fill content or // generate view code on fly. // can send view user db. return view(); }
for webforms check: https://msdn.microsoft.com/en-us/library/cc668177(v=vs.140).aspx
Comments
Post a Comment