This project is read-only.

How it works

How the application of the SharePoint theme is achieved

  1. A SharePoint Master Page contains all SharePoint styles and theme
  2. A custom page (MVCHostingPage) is based upon the SharePoint Master Page
  3. MVCHostingPage contains a web control called RenderControl
  4. RenderControl (and other internal classes) interrogates the current request and forwards it onto the ASP.mvc rendering engine.

The Sleight Of Hand

Then a HttpHandler is registered that points all requests to *.mvc to the MvcHostingPage.aspx
This way a sleight of hand is achieved. The url looks and acts like a ASP.mvc url but it is pre-processed, and wrapped, by the SharePoint theme.

SharePoint really has nothing to do with it

Now in reality this approach could be used to host ASP.mvc content in any existing website. So in theory it could be used as a transition approach for legacy websites.

Last edited Jan 11, 2009 at 8:32 AM by SimonCropp, version 3


No comments yet.