I have:
$.ajax({ type: 'POST',
url: myLink,
async: false,
dataType: 'html',
success : function(page) {
var fragment = page.find('#myId').html();
...
// I'll append my fragment to #somewhere
});
this is not working, console says page.find is not a function.
what am I doing wrong?
Try this…
pageitself is just a string containing the html you requested… So you have to first create a jQuery object to call jQuery methods on.