Come on, you could really invest some mental effort instead of asking us to do your work... It's not working out of the box, that much is clear. But you don't have to use two forms either...
<t:form> <t:select model="values" value="value" t:id="select" onchange="this.form.submit()" /> <t:if test="value"> <t:select model="strings" value="anotherValue" /> </t:if> </t:form> @Property private String[] values = { "foo", "bar" }; private String[] fooStrings = { "foo1", "foo2", "foo3" }; private String[] barStrings = { "bar1", "bar2", "bar3" }; @Persist @Property private String value; @Persist @Property private String anotherValue; public String[] getStrings() { if (value == null) return null; if (value.equals("foo")) return fooStrings; if (value.equals("bar")) return barStrings; return null; } public void onSubmitFromForm() { System.out.println("user selected " + value + " and " + anotherValue); if(value != null && anotherValue != null) ; //do something } Uli Am Mi, 8.10.2008, 14:36, schrieb [EMAIL PROTECTED]: > > Further to this, I can see it can be done using two forms, but that > isn't very nice. > > As this is such a common requirement (and one that I used without > problems in an application using Tapestry 3) I am somewhat surprised > that there are no examples offered as to how to do this in Tapestry 5. > > Further information would be much appreciated. > > thanks, > p. > > > Quoting [EMAIL PROTECTED]: > >> Quoting Ulrich Stärk <[EMAIL PROTECTED]>: >> >>> Do a form submit upon selecting something in the first dropdown, then >>> render the second dropdown according to the selection made. And vote >>> for >>> https://issues.apache.org/jira/browse/TAP5-138. >> >> >> Thanks, but I must be doing something wrong as I cannot get this to >> work (ignore the fact I have only one select dropdown on here for now): >> >> >> <form t:type="form"> >> Name Space: <select >> onchange="javascript:this.form.submit();" >> t:id="tagSelect" t:type="select" t:model="nsBases" t:value="nsBase" >> t:encoder="nsBases" t:blankOption="NEVER"></select> >> <input type="submit" value="Search"/> >> >> </form> >> >> >> >> void onSelectedFromTagSelect() >> { >> System.out.println("*******************************"); >> } >> >> >> How can I tell the submit comes from the select? I thought this would >> have worked but...? >> >> >> >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]