-
Notifications
You must be signed in to change notification settings - Fork 3
/
Global.asax
57 lines (40 loc) · 1.66 KB
/
Global.asax
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
<%@ Application Language="C#" %>
<%@ Import Namespace="System.Web.Routing" %>
<%@ Import Namespace="Composite.Core.Application" %>
<%@ Import Namespace="Composite.Core.Routing" %>
<%@ Import Namespace="Composite.Core.WebClient" %>
<script RunAt="server">
void Application_Start(object sender, EventArgs e)
{
ApplicationLevelEventHandlers.LogRequestDetails = false;
ApplicationLevelEventHandlers.LogApplicationLevelErrors = false;
ApplicationLevelEventHandlers.Application_Start(sender, e);
RegisterRoutes(RouteTable.Routes);
}
public static void RegisterRoutes(RouteCollection routes)
{
Routes.RegisterPageRoute(routes);
// If necessary, add the standard MVC route "{controller}/{action}/{id}" after registering the C1 page route
Routes.Register404Route(routes);
}
void Application_End(object sender, EventArgs e)
{
ApplicationLevelEventHandlers.Application_End(sender, e);
}
void Application_BeginRequest(object sender, EventArgs e)
{
ApplicationLevelEventHandlers.Application_BeginRequest(sender, e);
}
void Application_EndRequest(object sender, EventArgs e)
{
ApplicationLevelEventHandlers.Application_EndRequest(sender, e);
}
protected void Application_Error(object sender, EventArgs e)
{
ApplicationLevelEventHandlers.Application_Error(sender, e);
}
public override string GetVaryByCustomString(HttpContext context, string custom)
{
return ApplicationLevelEventHandlers.GetVaryByCustomString(context, custom) ?? base.GetVaryByCustomString(context, custom);
}
</script>