access database info in a partial view, .ascx that is included in Site.Master in asp.net mvc
- 阅读更多 关于 access database info in a partial view, .ascx that is included in Site.Master in asp.net mvc
问题 Hi i'm having problems with this. I am developing an asp.net mvc 2 application. I have a partial view menu.ascx defined. this gets included on all the pages of my site in the Site.Master masterpage. Now the thing is I want my menu to change according to the type of user. Here's what I did at first: <%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<dynamic>" %> <li><%: Html.ActionLink("Home", "Index", "Home")%></li> <% ExtendedMemberShip.MemberShipUser user =