Basically we are in a major hacky situation. We have a few web pages that is linked to from an other site. However, the requirement is that this site has the same layout as the site that linked to us. This was originally done by requesting the original page, scraping the layout, and wrapping out content in their layout.
This was rather simple in Web Forms as we could simply create a subclassed Page, that overrides the Render method and then wrapped anything we produced in the external sites layout. However, now this project is being rewritten in ASP.NET MVC.
How can we get acccess to the HTML result created by the MVC actions, modify them according to our needs and output the modified result to the browser?
After having tried tugberk’s solution which was insufficient I ended up creating a custom view result: