Created
June 6, 2018 09:40
Revisions
-
sniffdk created this gist
Jun 6, 2018 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,23 @@ public class PdfModule : IHttpModule { public void Init(HttpApplication context) { context.PostAuthorizeRequest += PostAuthorizeRequest; } void PostAuthorizeRequest(object sender, EventArgs e) { var context = HttpContext.Current; var url = context.Request.Url.AbsolutePath; if (!url.EndsWith(".pdf")) { return; } // do some logic here, then just return if no further action is needed } public void Dispose() { } }