addExternalLinks
is just a function, not a method of String (which is what .html
returns) nor is it a jQuery method to be chained.
$("#layerinfo").load(infoContent, function () {
addExternalLinks();
});
By the way, for addExternalLinks
couldn't you just add .attr("target", "_blank")
to said links instead of using a click event?