jQueryで文字列をjQueryObjectに変換する
var text = "<html>~</html>";
var obj = $(text);
メモメモφ(•ᴗ•๑)
例えば、
var text = "<div><span>foo</span></div><a>bar</a>"
var obj = $(text);
console.log( obj.find("div") ); //undefined
console.log( obj.find("a) ); //undefined
console.log( obj.find("span") ) //"foo"
となり、直下の要素はfind()出来ないので注意。
またhtml,header,bodyも無視される。