tomcat-taglibs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Helios Alonso <halo...@atg.com.uy>
Subject Re: Submit Button
Date Tue, 07 Sep 2004 14:56:41 GMT
Using the same name for all the submit buttons is cool for evaluating which 
one was pressed.  But if you don't want to use the buttons' text into the 
logic, different names would be nicer.

At 11:52 07/09/2004 -0300, you wrote:
>It seems that only one submit parameter is sent.
>
>I tried this html in Mozilla
>
><body>
><form action="sub.html" method="get">
><input type="submit" name="a">
><input type="submit" name="b">
></form>
></body>
>
>And when I press the first button only the a parameter is sent (it has no 
>value cause the input element doesn't have it).
>
>When I press the second button only the b parameter is sent.
>
>So, I would do something like this:
>
><c:if test="!empty param.a">The a button was pressed</c:if>
><c:if test="!empty param.b">The b button was pressed</c:if>
>
>At 10:31 07/09/2004 -0400, you wrote:
>>Looking for JSTL - not Struts.
>>
>>Quoting "Michael G. McGrady" <michael@michaelmcgrady.com>:
>>
>> >> Karl Coleman wrote:
>> >>
>> >> >I believe the name of the button is passed in the request under the
name
>> >> Submit.
>> >> >
>> >> >page.jsp?Submit=<name of your button>
>> >> >
>> >> >Karl
>> >> >
>> >>
>> >> Oh, if this is all you wanted to know, and not how to use images, blah,
>> >> blah, then you can use <html:submit> and the property attribute will
>> >> pass along the value to the ActionForm.  I assumed you wanted to know
>> >> more than this, since this is just how the submit tag works and I
>> >> assumed you looked at that.
>> >>
>> >> Michael
>> >>
>> >>
>> >> ---------------------------------------------------------------------
>> >> To unsubscribe, e-mail: taglibs-user-unsubscribe@jakarta.apache.org
>> >> For additional commands, e-mail: taglibs-user-help@jakarta.apache.org
>> >>
>> >>
>>
>>
>>David Schwartz
>>Array Software Inc.
>>http://www.arrayone.com
>>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: taglibs-user-unsubscribe@jakarta.apache.org
>>For additional commands, e-mail: taglibs-user-help@jakarta.apache.org
>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: taglibs-user-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: taglibs-user-help@jakarta.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: taglibs-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: taglibs-user-help@jakarta.apache.org


Mime
View raw message