jQuery.ajax({url: "/minicon_widget/95/"}).done(function(data) { $('script[src="/minicon_embed/95/"]').after(data); });