http://helma.org/bugs/show_bug.cgi?id=650 Summary: data missing from rec when using POST method
Product: Helma
Version: 1.6.3
Platform: All
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P2
Component: Web Support
AssignedTo:
helma-dev@...
ReportedBy:
kra5711@...
There is the following Javascript code in Helma:
res.write("1) Method: " + req.method + "<br>");
res.write("2) P-Rem: " + req.data.http_post_reminder + "<br>");
res.write("3) G-Rem: " + req.data.http_get_reminder + "<br>");
res.write("4) Params: " + req.params + "<br>");
res.write("5) Data: " + req.data + "<br>");
res.write("6) My data: " + req.data.mydata + "<br>");
When using GET method everything works fine:
<html><head><title></title></head><body>
<form method="get" action="
http://localhost:8080/testi">
<input type="hidden" name="mydata" value="ABC">
<input type="submit">
</form></body></html>
Server returns with GET:
1) Method: GET
2) P-Rem: null
3) G-Rem: null
4) Params: {mydata=ABC}
5) Data: {http_language=fi-fi,fi;q=0.8,en;q=0.5,en-us;q=0.3, mydata=ABC,
http_referer=
http://localhost:8080/static/koe.html, http_browser=Mozilla/5.0
(X11; U; Linux i686; fi-FI; rv:1.9.0.4) Gecko/2008111318 Ubuntu/8.10 (intrepid)
Firefox/3.0.4, HopSession=javax.servlet.http.Cookie@195dd5b,
http_host=localhost:8080, http_remotehost=127.0.0.1}
6) My data: ABC
But when GET method is replaced with POST, server can't see received data any
more and also the method has been changed:
<html><head><title></title></head><body>
<form method="post" action="
http://localhost:8080/testi">
<input type="hidden" name="mydata" value="ABC">
<input type="submit">
</form></body></html>
Server returns with POST:
1) Method: GET
2) P-Rem: null
3) G-Rem: null
4) Params: {}
5) Data: {http_language=fi-fi,fi;q=0.8,en;q=0.5,en-us;q=0.3,
http_referer=
http://localhost:8080/static/koe.html, http_browser=Mozilla/5.0
(X11; U; Linux i686; fi-FI; rv:1.9.0.4) Gecko/2008111318 Ubuntu/8.10 (intrepid)
Firefox/3.0.4, http_host=localhost:8080,
HopSession=javax.servlet.http.Cookie@1eb0, http_remotehost=127.0.0.1}
6) My data: null
Thus:
1) POST has been changed to GET
4) mydata is missing
5) mydata is missing
6) no value for mydata
The application have to use POST method because it sends a long charater
string to the server. Longer than GET method is able to handle.
--
Configure bugmail:
http://helma.org/bugs/userprefs.cgi?tab=email------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
_______________________________________________
Helma-dev mailing list
Helma-dev@...
http://helma.org/mailman/listinfo/helma-dev