--- Laila Zaman wrote:
> The drop down is bind with MySql database table, have id field 
> for value and name field for display in options.
> 
> ------------------------------
> id      name      address
> -------------------------------
> 1       henry     east town      
> 2       tom       north london
> 3       frank     west city
> --------------------------------
> 
> I have used an "onchange" eventhandler with drop down that 
> returns id value to the php page and the php code retrieves 
> the address value against that id like this

In such cases you have two options:

1. Use AJAX to load the data you need
2. Preload all data you might need in JavaScript array

I prefer the second choice whenever there isn't too much data
involved. Simple, load all 3 columns in JavaScript array and within
onChange event handler fetch the data you need from that array.

-- 

Milan Babuskov
http://www.guacosoft.com



Reply via email to