Before I had the following jQuery:
var dialogDiv = "<div id='" + dialogId + "'></div>";
$(dialogDiv).load(href, function () {
...
It worked fine.
Now I changed a little bit like this:
var dialogDiv = "<div id='" + dialogId + "' class='modal hide fade'><div class='modal-body'><p class='body'></p></div></div>";
$('.modal-body p.body').load(href, function () {
...
Now nothing is loaded into my jQuery dialog. Any idea?
Thanks.
The problem is that those elements don’t exist in the DOM yet. Wrap it in a jQuery object:
EDIT: Eventually you’ll have to insert that object in the DOM. You can chain
insertAfter($bla)to theload()event.