OK, your onchange code is going to have to use an XMLHttpRequest:

http://developer.apple.com/internet/webcontent/xmlhttpreq.html

and 

http://www.google.co.uk/search?hl=en&q=XMLHttpRequest&btnG=Google+Search&meta=

It will use one of these objects to send a request with whatever parameters are 
needed to producde the new combobox data back to a servlet which will send back 
a response.

The way I do this is I have the servlet send back a response of type 
"text/javascript", and send the javascript code to call those DOM methods and 
update the second combobox. (You did read those DOM documents didn't you?)

Back in the browser, in your javascript onreadystatechange handler which 
processes the response when the readyState == 4, you can eval() the 
responseText, and it will be executes. NB: Put a try{}catch{} round it so that 
you can highlight bugs in your returned javascript... takes a while to write 
bug-free javascript, especially when you have to compile your servlet and run 
your app to get the javascript out into the browser.

Don't forget to do a setTimeout() to call a failure method after a certain time 
- which is cancelled by the onreadystatechange handler on success - to handle 
server non-response!

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3913750#3913750

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3913750


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to