F
Fred
Strange problem. I have an html form that sends a POST request to a
servlet, but all the "request.getParameter()" requests are returning
null.
Here's a snippet:
public void doGet|Post(HttpServletRequest request,
HttpServletResponse response) throws ServletException, IOException
{
String baseDir = request.getParameter("baseDir");
String subDir = request.getParameter("subDir");
String description = request.getParameter("description");
if(debug)
{
log("baseDir = " + baseDir);
log("subDir = " + subDir);
log("description = " + description);
}
}
So the problem is that, even givin the exact same code for both, the
doGet method will display (in the log file) the values requested. In
the doPost method, it's always null values.
So what am I missing? I want to make it clear that doGet works (and I
can even see the values in the browser location bar).
servlet, but all the "request.getParameter()" requests are returning
null.
Here's a snippet:
public void doGet|Post(HttpServletRequest request,
HttpServletResponse response) throws ServletException, IOException
{
String baseDir = request.getParameter("baseDir");
String subDir = request.getParameter("subDir");
String description = request.getParameter("description");
if(debug)
{
log("baseDir = " + baseDir);
log("subDir = " + subDir);
log("description = " + description);
}
}
So the problem is that, even givin the exact same code for both, the
doGet method will display (in the log file) the values requested. In
the doPost method, it's always null values.
So what am I missing? I want to make it clear that doGet works (and I
can even see the values in the browser location bar).