Click here to Skip to main content
15,888,341 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi, I am new to the ASP.NET MVC2 website applications development. Looking for some guidance here. Top three questions:
Environment: ASP.NET 3.5 MVC2 website using Visual Studio 2008.

1. Website that i am building is 'Intranet' and more like a document repository at the moment.(not figured out the best approach for document storage,retrieval process)
2. Should be utilizing windows authentication.(Figured out)
3. Multi level left and top navigation menu.(Not figured out the best approach, tried downloading the jquery templates but none worked with the environment above, please suggest any compatible jquery templates).
4. Does MVC2 approach provide ability to control/edit the content on the website using webparts based on windows login/permissions defined on code-behind?

Please suggest for #1 and #3, and for #2 do you think MVC2 is best choice or should go with web form based website development with the constraints in environment.

Thank you!
-MT
Posted

0) Don't live in the past. Switch to MVC4, and if you can't upgrade a full blown version of VS to 2012, just download a Web Developer Express edition[^], I am pretty sure, it will be enough for you for the start.
1) Use entity framework[^] as "DAL+BL".
2) If you need to manage multiple and large files, you better use the FILESTREAM[^] functionality of SQL server instead of BLOBs (varbinary(max)), here is an example how to integrate with EF: http://blogs.microsoft.co.il/blogs/bursteg/archive/2008/05/12/ado-net-entity-framework-support-filestream.aspx[^]
3) Windows authentication is quite straightforward in MVC[^], mostly managed by IIS[^] itself, but authorization might be more complicated, especially in a domain environment.
4) Jquery is a good approach to the navigation, but better step forward with your environment than step back with jquery.
5) "webparts" are not mvc concepts. You can control anything, you have full control over the emitted html code, more than with web forms. But the possibility of editing the document is really dependent on the document format. So there is no single answer to this.
6) You might look around here to see some CMS implemented with MVC: http://www.codeplex.com/site/search?query=mvc%20cms&ac=4[^]
 
Share this answer
 
Comments
metharam 6-Aug-13 11:15am    
I guess I am almost there for answers around MVC, Thanks lot for the feedback.
Before I can accept this as a complete solution, couple more questions:

-Fortunately or unfortunately i will need to go to Framework 4.0 now. So from your notes, i will install Web Developer express edition for .NET 4.0 version . So,
1. can i install MVC4 templates and use it to develop the site?
2. Agreed to Filestream process.
3. Agreed to Windows Authentication
4. Within the Network contraints for browser compatability, i had to choose pure Css multilevel. Agreed.
5. Thanks for the info on webparts. I agree with the comments from :mgoad99
6. CMS implemented with MVC- good info thanks for this.
Zoltán Zörgő 6-Aug-13 14:39pm    
0) Take a little step further: EF 5, and .net 4.5.
1) Of course, see: http://www.asp.net/mvc/tutorials/mvc-4/getting-started-with-aspnet-mvc4/intro-to-aspnet-mvc-4
(All others were no question, so I couldn't answer to them.)
metharam 7-Aug-13 11:17am    
Thanks!
To help with your #4, in an MVC 4 intranet app i wrote, i setup the controller methods to restrict access based on roles.

Ex: Only administrators can get a view from this index method:
SQL
[Authorize(Roles="Administrators")]
        public ActionResult Index()
        {


This will keep people for accessing things they shouldn't

I also add something like this to menus in my views to control who will see what.
@if(Roles.IsUserInRole("Administrators"))
  {<ul><li>@Html.ActionLink("Click Here", "Index", "HomeController")</li></ul>}

Only administrators will be offered a "Click Here" link to the Index view in the Home Controller.

I hope that helps you to get started. Good luck!
 
Share this answer
 
Comments
metharam 5-Aug-13 15:58pm    
Hi , Is above solution applicable to this Environment: ASP.NET 3.5 MVC2 website using Visual Studio 2008.
mgoad99 5-Aug-13 15:58pm    
I believe so.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900