Help! I am using JQuery to make an AJAX call to fill in a drop-down dynamically given the user's previous input (from another drop-down, that is filled server-side). In all other browsers aside from Firefox (IE6/7, Opera, Safari), my append call actually appends the information below my existing option - "Select An ". But in Firefox, it automatically selects the last item given to the select control, regardless of whether I specify the JQuery action to .append or to replace (.html()).
<select name="Products" id="Products" onchange="getHeadings(this.value);">
<option value="">Select Product</option>
</select>
function getProducts(Category)
{
$.ajax({
type: "GET",
url: "getInfo.cfm",
data: "Action=getProducts&Category=" + Category,
success: function(result){
$("#Products").html(result);
}
});
};
Any thoughts? I have tried in the past to also transmit another blank first option, and then trigger a javascript option to re-select the first index, but this triggers the onChange event in my code, rather annoying for the user.