Swingline Rage
Swingline Rage

Reputation: 1130

ASP.NET MVC within DotNetNuke?

Is it possible to build a DNN module that uses ASP.NET MVC?

Granted that DNN doesn't support ASP.NET MVC out of the box...but since both DNN and MVC run on top of the ASP.NET pipeline...

The reason I ask. Large legacy website running on DNN:

http://blahblahblah.com

I'd like to stick an existing ASP.NET MVC webpage/application here:

http://blahblahblah.com/subfolder

Is this better done by setting up a virtual directory etc on the server, or is there a way to integrate this with DNN?

Upvotes: 5

Views: 6880

Answers (4)

JBeckton
JBeckton

Reputation: 7111

Download my DnnMvcBridge project and you can absolutely build DNN modules with MVC 4 and Razor.

https://dnnmvcbridge.codeplex.com/

Upvotes: 3

bdukes
bdukes

Reputation: 155895

If you just want a separate MVC application in a subdirectory, you should be able to do that. The main tricky part would be integrating users/sessions (assuming you need to), but that shouldn't be too big a hurdle to figure out (as opposed to re-coding your existing MVC application). You will probably also need to update the web.config for your MVC application to clear out anything from DNN (most importantly, the HTTP Modules and Handlers, so they don't interfere with routing).

Upvotes: 0

hernant
hernant

Reputation: 351

For Asp.Net MVC, take a look to this:

http://www.charlesnurse.com/post/Developing-Modules-for-DotNetNuke-using-ASPNET-MVC-Part-1-Introduction.aspx

and this:

http://bigfootmvc.codeplex.com/

which is not Asp.Net MVC, but another MVC framework (it's supposed to not require anything not native to the DNN dev environment).

Upvotes: 1

ScottS
ScottS

Reputation: 8543

DNN is quite tightly tied to Webforms. ASP.Net MVC would be very difficult, maybe impossible to integrate in a module. However DNN does support Webforms MVP (Model View Presenter) which allows for all of the structural/testing benefits of MVC in the WebForms context. All new modules developed by DotNetNuke Corp. are using the Webforms MVP pattern.

Here is a link to get you started Step by Step Webforms MVP and DotNetNuke – Part 1.

Upvotes: 8

Related Questions