Files
ayanova7/source/WBI/AyaFileHandler.ashx
2018-06-29 19:47:36 +00:00

26 lines
764 B
Plaintext

<%@ WebHandler Language="C#" Class="AyaFileHandler" %>
using System;
using System.Web;
public class AyaFileHandler : IHttpHandler, System.Web.SessionState.IReadOnlySessionState
{
public void ProcessRequest (HttpContext context) {
string idstring = context.Request.QueryString["id"];
Guid oID = Guid.Empty;
if (!string.IsNullOrEmpty(idstring))
oID = new Guid(idstring);
if (context.Request.QueryString["d"] == "1")
Util.DeleteAyaFile(context.Response, oID, context.Request.UrlReferrer.ToString());
else
Util.WriteAyaFileToResponse(context.Response, oID);
}
public bool IsReusable {
get {
return false;
}
}
}