Reputation: 639
I'm trying to dynamically load html into a popup using ajax with this:
$('body').load( new_url, function (responseText, textStatus, XMLHttpRequest ) { ... } );
It works fine, but it doesn't load the html into the subwindow, it loads it into the opening window. If I have a reference to the subwindow "win", how can I do something like this:
win.$( 'body' ).load...
currently, that gives an error saying win.$ is not a function
.
Thanks!
Upvotes: 1
Views: 348
Reputation: 14282
Try this instead ::
$("body", win.document).load(URL, function() {
// do your stuff
});
Hope this will help !!
Upvotes: 1