[
https://issues.apache.org/jira/browse/WICKET-2774?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12843917#action_12843917
]
Joachim F. Kainz commented on WICKET-2774:
------------------------------------------
this is what my Jetty request object looks like:
GET
/home?inputForma_hf_0=&home%2Fwicket%3Ainterface%2F%3A11%3AinputForm%3A%3AIFormSubmitListener%3A%3A=&a=1&b=2
HTTP/1.1
Host: preding.walmart.com:8080
User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.2pre)
Gecko/20100216 Ubuntu/9.10 (karmic) Namoroka/3.6.2pre
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Accept-Language: en-us,en;q=0.5
Accept-Encoding: gzip,deflate
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
Keep-Alive: 115
Connection: keep-alive
Referer:
http://preding.walmart.com:8080/home?inputForm9_hf_0=&home%2Fwicket%3Ainterface%2F%3A10%3AinputForm%3A%3AIFormSubmitListener%3A%3A=&a=1&b=2
Cookie: cef.secureenv=wmomsq3; s_vid=e3942a0c1b7c314a8a1847e179f937e8cfda;
com.wm.anoncart=106062620377231400; com.wm.visitor=1060626203;
com.wm.reflector="reflectorid:0000000000000000000...@lastupd:1268277148...@firstcreate:1268277148676";
cef.env=wmomsq3;
WMSessionID=000000007c63fc173fd65963dbaea3b23fdd477f51b82628_1268277095059_SSL201_172-28-184-22_1268277148639_10.3_N_;
JSESSIONID=6hw04lrsdxzx
When WebRequestCodingStrategy#addInterfaceParameters(Request,
RequestParameters) tries to extract the wicket:interface parameter it gets null.
> Form#onSubmit() not called in StatlessForm on pages mounted using
> WebPage#mountBookmarkablePage(String, Class)
> --------------------------------------------------------------------------------------------------------------
>
> Key: WICKET-2774
> URL: https://issues.apache.org/jira/browse/WICKET-2774
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.4.6, 1.4.7
> Environment: j...@preding:~/workspace/wicket-stateless$ uname -a
> Linux preding.walmart.com 2.6.31-20-generic #57-Ubuntu SMP Mon Feb 8 09:02:26
> UTC 2010 x86_64 GNU/Linux
> j...@preding:~/workspace/wicket-stateless$ java -version
> java version "1.6.0_0"
> OpenJDK Runtime Environment (IcedTea6 1.6.1) (6b16-1.6.1-3ubuntu1)
> OpenJDK 64-Bit Server VM (build 14.0-b16, mixed mode)
> Reporter: Joachim F. Kainz
>
> I am using the following simple application class:
> public class WicketApplication extends WebApplication {
> @Override
> public Class<HomePage> getHomePage() {
> return HomePage.class;
> }
> @Override
> protected void init() {
> mountBookmarkablePage("home", HomePage.class);
> }
> }
> HomePage.html looks like this:
> <html
>
> xmlns:wicket="http://wicket.apache.org/dtds.data/wicket-xhtml1.4-strict.dtd">
> <head>
> <title>Stateless Wicket</title>
> </head>
> <body>
> counter 2:
> <form wicket:id="inputForm" method="get">
> <label for="a">a:</label>
> <input wicket:id="a" id="a" type="text" size="15"/><br/>
> <label for="b">b:</label>
> <input wicket:id="b" id="b" type="text" size="15"/><br/>
> <input type="submit" value="Execute" />
> </form>
> </body>
> </html>
> HomePage.java:
> public class HomePage extends WebPage {
> public HomePage(final PageParameters parameters) {
> final Form<String> form = new StatelessForm<String>("inputForm") {
> private static final long serialVersionUID =
> -1804691502079814185L;
> @Override
> protected void onSubmit() {
> info("clicked sumbit");
> }
> };
> final TextField<String> a = new TextField<String>("a",
> new Model<String>(_a));
> final TextField<String> b = new TextField<String>("b",
> new Model<String>(_b));
> form.add(a);
> form.add(b);
> add(form);
> }
> }
> This very simple code example shows that the StatlessForm#onSubmit() function
> is never called iff mountBookmarkablePage("home", HomePage.class) is in
> WicketApplication#init(). If I remove this statement from the code, the
> onSubmit() method is called as expected.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.