52 lines
1.2 KiB
C#
52 lines
1.2 KiB
C#
using log4net.Config;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.IO;
|
|
using System.Linq;
|
|
using System.Web;
|
|
using System.Web.Security;
|
|
using System.Web.SessionState;
|
|
|
|
namespace TiJianFuWu
|
|
{
|
|
public class Global : System.Web.HttpApplication
|
|
{
|
|
|
|
protected void Application_Start(object sender, EventArgs e)
|
|
{
|
|
var logCfg = new FileInfo(AppDomain.CurrentDomain.BaseDirectory + "log4net.config");
|
|
XmlConfigurator.ConfigureAndWatch(logCfg);
|
|
}
|
|
|
|
protected void Session_Start(object sender, EventArgs e)
|
|
{
|
|
var log = log4net.LogManager.GetLogger(this.GetType());
|
|
log.Info(Session.SessionID);
|
|
}
|
|
|
|
protected void Application_BeginRequest(object sender, EventArgs e)
|
|
{
|
|
|
|
}
|
|
|
|
protected void Application_AuthenticateRequest(object sender, EventArgs e)
|
|
{
|
|
|
|
}
|
|
|
|
protected void Application_Error(object sender, EventArgs e)
|
|
{
|
|
|
|
}
|
|
|
|
protected void Session_End(object sender, EventArgs e)
|
|
{
|
|
|
|
}
|
|
|
|
protected void Application_End(object sender, EventArgs e)
|
|
{
|
|
|
|
}
|
|
}
|
|
} |