jQuery.load and form elements
- by Jez
Is jQuery's .load() supposed to be able to load elements? Because it seems to be stripping them out. So I have some code like:
var $dialogContents = $('<div></div>').load($link.attr('href') + ' #divDlgContent', function() { ... }
and when the $dialogcontents loads, I return some content with a inside the DIV with the id 'divDlgContent'. Although the rest of the HTML is loaded, the tags are stripped out. Is this by design, and is there a way I can load elements this way?