public virtual void ProcessRequest(HttpContext context) { context.Response.ContentType = "text/plain"; coding = CreateCoding(context); ReadContext = CreateReadContext(context); WriteContext = CreateWriteContext(context); string type = context.Request.QueryString["t"]; if (context.Request.RequestType.ToLower() == "post") { try { Dictionary <string, object> kv = ReadContext.ToDictionary(); string str = ProcessRequestPostHandler(type, kv); Write(context, str); } catch (Exception ex) { Log.writeLog("ProcessRequest", ex.ToString(), type); } } else { string str = ProcessRequestGetHandler(type); Write(context, str); } }
public WebHelper(IReadContext ReadContext) { this.ReadContext = ReadContext; kv = ReadContext.ToDictionary(); }