How to preload combo box div in jquery
I have code like this:
$("#item_select").change(function()
{
var params = $("#item_select option:selected").val();
$.post('/account/ar_form.php', {idata: params}, function(data){
$("#message_display" ).html(data);
});
});
This is the dropdown that uses / account / ar _form.php to display the html in the div correctly.
But it only shows up in the change event. I would like it to preload the data. When I use the load event, it displays the html, but when changed, it displays it twice.
0
a source to share
2 answers