I know you can populate a form dropdown with data from a database based on the selection of another dropdown with Ajax.

I don't have any experience with Ajax, but I need to get this project done for my work.

If anyone cane help me with this I'd really appreciate it.

Here is the code for my first dropdown.
PHP Code:
"SELECT * FROM wp_flr_flights"
$flight_result mysql_query($flight_sql); 
'<select name="location">'
    while (
$flt_loc_rows mysql_fetch_assoc($flight_result)) { 
$loc_id $flt_loc_rows["location_id"]; 
$loc_name $flt_loc_rows["location_name"]; 
''<option value="'.$loc_id.'">'.$loc_name.'</option>''
So what I want to happen, is when the dropdown is selected the next three dropdowns on the form are populated based in the $loc_id variable.
SO every row in the table with (let's say) and $loc_id of 1. The form gets populated on with information from those rows.

I hope that make sense. I apologize if I posted in the wrong area. I'm not sure if this should be PHP or JavaScript.

Thanks in advanced