I m working on a mini CMS-like application using asp.net MVC 1.0 (I will upgrade it once 2.0 is released). Once feature I want, that is pretty vital to a CMS, is the ability for an admin to add pages to their site.
Essentially, if the admin wants to add a page called "Links", I want them to be able to do so without having to go through any of the hassle of adding the action to the controller and compiling a new assembly.
I have an idea for a solution and I want to know what the community thinks.
I think that I should write a class called (for arguments sake let s call it UserGeneratedGenericController) that extends the Controller class. In this class, I will have a single Action that reads a parameter and redirects to the View that corresponds with the parameter passed to the action.
I will also have to edit the Routing in the Global.asax.cs
file
therefore
/UserGeneratedGenericController/Links
will hit the same Action that
/UserGeneratedGenericController/News
will hit, but will display the views as desired.
What say you? I m interested in your comments on this approach and your suggestions to other approaches.