Ejemplo n.º 1
0
 void context_BeginRequest(object sender, EventArgs e)
 {
     var context = (HttpApplication) sender;
     if (!context.Request.RawUrl.IsRequestConsideredForCounts())
         return;            
     var request = new Request
         {
             RelativeUrl = context.Request.RawUrl,
             FullUrl = context.Request.Url.AbsoluteUri,
             ReceivedDate = DateTime.Now
         };
     _blogCountsDataContext.InsertRequest(request);
 }
 public void InsertRequest(Request request)
 {
     Requests.Add(request);
     SaveChanges();
 }