I load an html page containing a jquery function with Ajax.
Page A calls Page B with ajax. In Page B, some HTML is generated and contains some jquery functions. But I think he tries to run the jquery on page B. I get errors $ is undefined
and my jquery source are in Page A.
Can I prevent the execution of javascript on Page B?
Here is my call from Page A:
var options = {
dataType: 'html',
beforeSubmit: function () {
$('#' + s_Target_Response).animate({
opacity: 0
});
},
success: function (response) {
$("#loading").offset({ top: 1, left: 1 });
$('#loading').hide();
Init();
$('#' + s_Target_Response).html(response);
$('#' + s_Target_Response).animate({
opacity: 1
});
}
};
// pass options to ajaxForm
$('#' + s_Target_Form).ajaxForm(options);
$('#' + s_Target_Form).submit();