|
View:
New views
7 Messages
—
Rating Filter:
Alert me
|
|
|
[Bug 650] New: data missing from rec when using POST methodhttp://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 |
|
|
[Bug 650] data missing from rec when using POST methodhttp://helma.org/bugs/show_bug.cgi?id=650
------- Comment #1 from hannes@... 2008-11-19 22:17 ------- Works for me. I'm using the following action: function test_action() { 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>"); res.write( '<form method="post" action="http://localhost:8080/test">\ <input type="hidden" name="mydata" value="ABC">\ <input type="submit">\ </form>'); } Can you please confirm you can reproduce the bug with this code in the root prototype directory? -- 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 |
|
|
[Bug 650] data missing from rec when using POST methodhttp://helma.org/bugs/show_bug.cgi?id=650
------- Comment #2 from kra5711@... 2008-11-26 13:00 ------- Yes, the problem still exists. The name test_action() did not work, but the name main_action() was found by server. The configuration is: Root directory: /home/user1/Helma/helma-1.63 Function main_action() is placed in file: /home/user1/Helma/helma-1.63/apps/test/Root/actions.js In apps.properties the only inserted line is: test Java version is: 1.6.0_10 Works fine with GET method. But POST does not work neither Linux nor Windows 2000 Professional SP4. -- 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 |
|
|
[Bug 650] data missing from rec when using POST methodhttp://helma.org/bugs/show_bug.cgi?id=650
------- Comment #3 from chris@... 2008-11-26 14:46 ------- Looks like the problem happens when a post request doesn't reference an action name and the trailing slash is missing. -- 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 |
|
|
[Bug 650] data missing from rec when using POST methodhttp://helma.org/bugs/show_bug.cgi?id=650
------- Comment #4 from hannes@... 2008-11-26 16:04 ------- (Mit Bezug zu comment 3) > Looks like the problem happens when a post request doesn't reference an action > name and the trailing slash is missing. > Still can't reproduce this. But what I think might be going on is that the POST request is bing redirected. That's pretty much the only reasonable explanation I can think of. -- 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 |
|
|
[Bug 650] data missing from rec when using POST methodhttp://helma.org/bugs/show_bug.cgi?id=650
------- Comment #5 from kra5711@... 2008-11-26 22:31 ------- After inserting trailing slash to form's action the system seems to be working. Thank you! -- 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 |
|
|
[Bug 650] data missing from rec when using POST methodhttp://helma.org/bugs/show_bug.cgi?id=650
hannes@... changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |WONTFIX ------- Comment #6 from hannes@... 2008-11-27 10:57 ------- I was now able to reproduce the bug. It only happens when you POST to the main action of the root object of a helma app without trailing slash, because Jetty (the web server that is bundled with Helma) redirects that request to a URL with trailing slash added. You could argue that Jetty could be smarter about this and not redirect POST requests this way, and maybe this is alreay fixed in newer versions of Jetty. However the problem seems easy enought to workaround, so I'm closing it as WONTFIX. -- 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 |
| Free embeddable forum powered by Nabble | Forum Help |