ASP.NET MVC Areas with shared layout

前端 未结 1 573
醉酒成梦
醉酒成梦 2021-02-01 02:15

I have defined an area (Admin) in my ASP.NET MVC 3 application, created _ViewStart.cshtml in that area and addedLayout = \"~/Views/Shared/_Layout.cshtml\";

1条回答
  •  误落风尘
    2021-02-01 02:35

    Simply specify a blank area for them if they are to be served from root controllers:

  • @Html.ActionLink("About Us", "About", "Home", new { area = "" }, null)
  • 0 讨论(0)
提交回复
热议问题