You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Rajesh <ra...@cevalsoft.com> on 2010/11/23 07:48:30 UTC
Dropdown box fetch values from JS.
Hi All,
Actually I have a requirement, which fetch the drop down values
from JS and show it in jsp.
I have to use ajax auto completer to achieve this.
Here the issue is, i can able to enter any value in the auto
completer box and pass that value to database.
My question - how can i will not enter any value in the auto
completer drop down? is this possible?.
else please suggest me any other way to achieve this.
Here is my code.
Js File
[
["Hourly","Hourly"],
["Contract","Contract"],
["Permanent","Permanent"],
["Decide Later","Decide Later"]
]
In my JSP
<s:url var="rateOptionJSONList" value="/rateOptionJSONList.action"/>
<sx:autocompleter
indicator="indicator1"
href="%{rateOptionJSONList}"
autoComplete="false"
forceValidOption="true"
value="Hourly"
name="req.rateOption"/>
Here i dont want to enter any value.Just click on the drop down i will
show the values which present in that JS file.
--
*Rajesh.R*
*Software Engineer*
Tel: 91-44-42115406
Email: rajesh.ranganathan@cevalsoft.com
<ma...@cevalsoft.com>
Site: http://www.cevalsoft.com