As a complete novice, I am using a similar starter kit (BlogEngine.Net). I have a master page (site.master) that controls the general layout for the rest of my .aspx pages. I want all the pages to display the same general content except for one page (home.aspx). I would like part of the masterpage content hidden on home.aspx. Is there a way to write a conditional statement in the master page that will allow or disallow some of the master page content to be displayed based on which .aspx file is active?
If home.aspx is the active page, then hide part of site.master contents. Else-If home.aspx is not the active page, then display all the contents of site.master.
Below are partial contents of site.master (my master page). There is an if statement (bolded below) dealing with site administration stuff that displays administrator content when logged into the site (makes me think my idea is possible). When home.aspx is active, I would like to hide the content that is lined out.
<body>
<form id="form1" runat="server">
<div id="menu">
<ul>
<li><a id="A1" href="~/home.aspx" runat="server"><%=Resources.labels.home %></a></li>
<li><a id="A2" href="~/about.aspx" runat="server"><%=Resources.labels.about %></a></li>
<li><a id="A3" href="~/default.aspx" runat="server" rel="home"><%=Resources.labels.blog %></a></li>
<li><a id="A4" href="~/contact.aspx" runat="server"><%=Resources.labels.contact %></a></li>
<li><a id="A5" href="~/archive.aspx" runat="server"><%=Resources.labels.archive %></a></li>
</ul>
</div>
<div id="main">
<div class="sidecol" id="sidebar">
<ul>
<li>
<h2>About</h2>
</li>
<% if (Page.User.Identity.IsAuthenticated){ %>
<li>
<h2>Administration</h2>
<uc1:menu ID="Menu1" runat="server" />
</li>
<%} %>
<li>
<h2>Disclaimer</h2>
</li>
</ul>
</div>
</div>
</form>
</body>