Questions tagged [asp.net-mvc-areas]

An organizational concept present in ASP.NET MVC, that allows the developer to partition a large web application into smaller units.

An organizational concept present in ASP.NET MVC, that allows the developer to partition a large web application into smaller, distinct units. Areas might be used to, for instance, divide an application into inventory, review, storefront, and administration modules.

More information

575 questions
0
votes
2 answers

3 MVC projects in 1 Solution

I have to build 3 MVC web applications using Entity Framework (www.company1.com www.company2.com www.company3.com). The websites will all access the same sql server database, but will be slightly different in their own way (appearance, data etc).…
tcode
  • 5,055
  • 19
  • 65
  • 124
0
votes
1 answer

ViewBag and Models are not avaialable when tried Pluggable MVC areas

I have tried the pluggable structure as discussed in this post: Pluggable MVC view return null It is also explained in this post: http://www.wynia.org/wordpress/2008/12/aspnet-mvc-plugins/ When I try to access ViewBag/Model in one of the area, it…
0
votes
1 answer

Portable Areas in MVC 4

Has anyone gotten Portable Areas working in MVC 4? I have gotten PAs working in MVC 3 by following this tutorial. However, when changing the consuming application to MVC 4, Portable Areas no longer work. It also seems that it doesn't matter if…
FunkMonkey33
  • 1,956
  • 2
  • 16
  • 24
0
votes
1 answer

How do I redirect to an other area in MVC3?

I have 3 areas at the moment (more will come when I get this working): Login, User and Admin. The Default route in Global.asax go to the index action of the index controller in the login area (Login\Index\Index) which works fine, this is how I…
Ben
  • 5,525
  • 8
  • 42
  • 66
0
votes
2 answers

Why my view action links including current action params in MVC3

I am working on a MVC3 application. In my view I am using @Html.ActionLink for anchor links. Every thing working fine. But those links are including the current url's params in the link. If my current link is http://localhost:25466/Blog/all/2 Action…
0
votes
1 answer

Consuming Web Api's as HttpPost

Can somebody help me how to post an array of type long to a WebApi. I think I have to use PostAsync from HttpClient, but I am not sure how to put array to HttpContent. This is my controller. [HttpPost] [Authorize] public void…
0
votes
1 answer

Site navigation for an 'Admin' application in ASP.NET MVC

I've made an Area project for my ASP.NET MVC application called 'Admin'. This will contain all the logic for the Administration section of the site, where the users can add/remove pages, etc. There's a menu at the top, of things the user can manage.…
Jonathan
  • 32,202
  • 38
  • 137
  • 208
0
votes
1 answer

Multiple layouts for ASP.Net MVC 4

I have a _ViewStart.cshtml in my main view folder with the following code. @{ Layout = "~/Views/Shared/_Layout.cshtml"; } In the View folder of my admin area I have a _ViewStart.cshtml with this code @{ Layout = Request.IsAjaxRequest() ?…
Jhorra
  • 6,233
  • 21
  • 69
  • 123
0
votes
1 answer

Access static content from area w/o "Areas" in url

I am currently working on a web app with a small web page on the root level and several (more complex) web pages in areas. All area-based web pages have static content that is independant of each other, so each of them has it's own content…
Pharao2k
  • 685
  • 4
  • 24
0
votes
1 answer

ApiController within an area

I want to have BlaController : ApiController, with BlaController located in /Areas/XXX/ ( or namespace MySolution.Areas.XXX.Controllers ) The problem is that when I browse to http://localhost:1935/XXX/Bla/SomeAction I get 404. Normal controllers (:…
sports
  • 7,851
  • 14
  • 72
  • 129
0
votes
1 answer

Howto: Nested Layouts in Areas?

I have an ASP .NET MVC3 (razor) site following this structure: Site1 -Areas -Area1 -Views -SomeFeature -Index.cshtml --> sets the section 'pageScripts' -Shared …
abjbhat
  • 999
  • 3
  • 13
  • 24
0
votes
1 answer

cannot get web.config file in area folder to work

I created a new area "admin", add following code to web.config in the admin area. if I go to admin page without logging in, I still get redirected…
qinking126
  • 11,385
  • 25
  • 74
  • 124
0
votes
2 answers

MVC routing issues, areas and HTML actionlinks

I've looked for this for a while and the solutions look like they should work, it appears I'm doing it wrong. I created an area for administering the CMS side called "manage" so if you go to: /Manage/Vinyard it will give you a list of vinyards to…
Snowburnt
  • 6,523
  • 7
  • 30
  • 43
0
votes
0 answers

ASP.NET MVC 3 Routes Always Have Querystring Value "Area="

This is an annoyance that I've experienced for a long time, but now my client is asking me to address it. In every route that gets generated (by a non-Default route), a query string value gets appended: "Area=" As an example: //…
Jay Querido
  • 1,257
  • 1
  • 12
  • 15
0
votes
1 answer

Why links generated with @Url.Action in JavaScript are not in lowercase when using AttributeRouting?

I have this code in a JavaScript function: var url = '@Url.Action(MVC.Membership.User.ActionNames.Update, MVC.Membership.User.Name)'; url += "?userName=" + userName; ul.append("
  • " + userName + "
  • "); Membership is…
    1 2 3
    38
    39