struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kakoli Sen (kasen)" <ka...@cisco.com>
Subject Basic Struts doubt
Date Sun, 28 Oct 2012 17:33:41 GMT
Hello all,
    I am a newbie in Struts and JSP.
My initial JSP page is coming out where I have among other widgets, 2 combo boxes. The user
selects from the first combo and then the second combo needs to be populated from db based
on the value selected.
                How do I call executeAction method of Action class when the first combo box
value is changed?
Attaching my Struts-config.

My JSP code snippet is thus :
<tr>
<td><label for="track_name">Track Name</label></td>
                <td><input type="hidden" value="myAction" /></td>
                <td><html:select name="TrackBaselineConfigActionForm"
                                                property="selTrackName" onchange="this.form.myAction.value='getOsVersionAction';
                                                                                         
      this.form.submit();">
                <option value="">Select...</option>
                <html:optionsCollection  property="trackList" label="selLabel" value="selLabel"
/>
                </html:select></td>
</tr>
<tr>
                <td><label for="os_version">OS Versions</label></td>
                <td><html:select name="TrackBaselineConfigActionForm"
                                                                                         
      property="osVersion">
                <option value="">ALL</option>
                <option value="">Standard Recommended Version</option>
                <!-- html:options name="TrackBaselineConfigActionForm" property="osVersions"
/-->
                </html:select></td>
</tr>

Thanks in Advance,
Kakoli

Mime
View raw message