aspose file tools
The moose likes JSP and the fly likes A question about the form Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » JSP
Reply Bookmark "A question about the form" Watch "A question about the form" New topic
Author

A question about the form

Ning Du
Greenhorn

Joined: Jul 08, 2003
Posts: 11
Hi,
In one of my JSP page I have two SELECT fields in a form,the requirment is that the options of the second SELECT field changes along with the selected option of the first SELECT field. How can I do that? JavaScript?


SCJP1.4
sunitha reghu
Ranch Hand

Joined: Dec 12, 2002
Posts: 937
yes you can do that using a javascript. If the no of records are few then using JS is not a problem. But if the number of records are big say abt 800
then using using wddx u can do that.
Ning Du
Greenhorn

Joined: Jul 08, 2003
Posts: 11
Thanks for your reply,
but I don't know what you mean by"But if the number of records are big say abt 800, then using using wddx u can do that. "
[ August 23, 2003: Message edited by: Adu Ning ]
Faisal Khan
Ranch Hand

Joined: Jun 29, 2003
Posts: 285
Adu,
Sunitha is saying that if you have a select box with huge number of entries then using JavaScript is not a good solution. In most cases it should be OK.
You can populate javascript arrays and do all the processing on client side or use server side processing thus reloading the page when an option is selected in the first select box.

IHTH
- FK


The secret to creativity is knowing how to hide your sources.
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: A question about the form
 
Similar Threads
Validation problem with Struts1.2
Show a hidden text field
How to list down a text file in a list/menu
javascript dropdown over text field
Require help in submitting <form> through JavaScript function