-
Notifications
You must be signed in to change notification settings - Fork 0
/
SiteMaster1.master.cs
41 lines (40 loc) · 1.43 KB
/
SiteMaster1.master.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
public partial class SiteMaster1 : System.Web.UI.MasterPage
{
protected void Page_Load(object sender, EventArgs e)
{
if (HeadContent.Page.AppRelativeVirtualPath.ToLower().Equals("~/default.aspx"))
{
Start.Attributes.Add("class", "active");
}
else if ((HeadContent.Page.AppRelativeVirtualPath.Equals("~/Bilder.aspx")) || (HeadContent.Page.AppRelativeVirtualPath.Equals("~/Ritningar.aspx")) || (HeadContent.Page.AppRelativeVirtualPath.Equals("~/Kartor.aspx")))
{
Bilder.Attributes.Add("class", "active");
}
else if (HeadContent.Page.AppRelativeVirtualPath.Equals("~/Information.aspx"))
{
Information.Attributes.Add("class", "active");
}
else if (HeadContent.Page.AppRelativeVirtualPath.Equals("~/Blog.aspx"))
{
Blog.Attributes.Add("class", "active");
}
else if (HeadContent.Page.AppRelativeVirtualPath.Equals("~/Regler.aspx"))
{
//Regler.Attributes.Add("class", "active");
}
else if (HeadContent.Page.AppRelativeVirtualPath.Equals("~/Styrelsen.aspx"))
{
Styrelsen.Attributes.Add("class", "active");
}
else
{
Information.Attributes.Add("class", "active");
}
}
}