Anyone know how to access HTTP POST data in the Padarn web server? They wrote the POST data will be in Requ开发者_如何学JAVAest.Form, but there is always nothing.
We'd need to see more of your code. Is this a Page or is it a custom IHttpHandler? What version of Padarn are you using? I just tested the following and it output the POST data as expected:
public class Target : Page
{
protected override void Page_Load(object sender, EventArgs e)
{
Response.Write("<b><u>Request.Form.Keys</u></b><br>");
Response.Write("<ul>");
foreach (var key in Request.Form.AllKeys)
{
Response.Write(string.Format(
"<li>Key: '{0}' Value: '{1}'", key, Request.Form[key]));
}
Response.Write("</ul>");
// flush
Response.Flush();
}
}
精彩评论