开发者

Use different .Net Framework for subfolder

I have the requirement to build a simplier admin interface for a website. I believe MVC 3 (I want to use .Net 4) would be a good fit, but the main site is using webforms and .Net 3.5. Is it possible to have a sub开发者_JS百科folder using MVC 3 (I would build a new solution) without affecting the main application? Is there any issues if it possible? So I would have www.mysite.com as asp.net 3.5 web forms and www.mysite.com/simplifiedadmin as the MVC 3 project. Any help, opinions, or advice is welcomed. Thanks.

Edit:

Just to be clear to future readers, when I mention the 3.5 framework it is in reference to what I am using as a target framework in VS. The application pool will references the 2.0 framework on IIS. Thanks Josh for pointing that out.


You have to use two different Application pools, but that is certainly possible in IIS by creating a new Application within the site (in IIS Manager) and giving it a .net 4 Application Pool.

PS: You could also use ASP.net MVC 2 on .net 3.5 if that makes things simpler.


Firstly you seem to be confused about what a sub domain is. If your main site was on www.mysite.com and your administration site was on admin.mysite.com that would be a sub-domain, as it stands, from reading the question that isn't a sub-domain, you want it in a separate directory.

It is possible if you have full control over IIS - you would create an application pool for the new application with the right version of the .NET framework and then, once you've create the new directory, right click it in IIS Manager and choose convert to application. Once that's done right click the folder and choose Manage Web Site -> Advanced Settings and change the application pool.


That is not a subdomain, that is a subfolder.

A subdomain to mysite.com would be simplifiedadmin.mysite.com. (www.mysite.com is actually also a subdomain to mysite.com.) A subdomain has its own DNS record, so it's quite easy to run as a separate application, or even on a different server.

A subfolder can also run as a separate application, but it has to be on the same server. You can either put a subfolder in the web and make it an application in IIS, or you can create a virtual directory that points to a folder somewhere else on the server, and make that an appliction.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜