Consider two select box, the 1st with country the 2nd with city, I want when someone select counrty in the 1st box the 2nd to contain only the cities of that country, plus I do not want to refresh the whole page because these two boxes are part of a search form below of we show the results of the search. So I thought using AJAX.
In the first solution when I placed the 2nd select box inside a div and add an onChange event on the 1st, so when the user selected a country the Ajax would replace whatever was inside the div (the existing select box) with another select box with the desired cities (both the existing and the new one had the same name and id-cities), worked perfectly in IE but in firefox it doesn't store the $_POST['cities'] so I can search based on the city (all the other fields of the form like the country works perfectly)
In the second solution I removed the div and put the id I wanted in the id of the selectbox (now the select box had name=cities, id something else) and so the only thing dynamically produced was the <option>,</option> worked perfectly on firefox but in IE it produces an empty select box
Help anyone...