Hi,
I do have some trouble with a modal dialog with ui jquery.
I have to pass a param to a page and return the content within the modal dialog.
I works fine for the first call but, without reload of the page, on next calls it is always the first selected value that is passed.
Here's part of the code :
- $("#beer_list > div > li").live("dblclick", function()
{ var passed_param =$(this).attr("id");
var dialogOpts =
{ title: "My First AJAX dialog",
modal: true,
autoOpen: false,
height: 500,
width: 500,
open: function()
{ //display correct dialog content
$("#example").load("./test.php", {limit:passed_param}, function()
{ alert('Load was performed.'+passed_param);
});
}
};
$("#example").dialog(dialogOpts);
$("#example").dialog("open");
});
On alert on passed_var it is always fine (line 2), but on alert within "dialogOpts" (line 11) it is always the first one that pops up.
Any idea ?
thx,