Library: Bootstrap 3:Collapse.js.
I have tried
$(document).ready(function () {
Sys.WebForms.PageRequestManager.getInstance().add_endRequest(endRequestHandler);
});
function endRequestHandler(sender, args) {
//alert("this should work");
$('#collapseTwo').collapse.in();
But it throws Uncaught TypeError: undefined is not a function
The alert instead works no problem.
I thought JQuery was undefined but the page where this code is inherits all the appropriate scripts from a masterpage, so that's not the problem.
So, following this advice I went on to trying
Sys.WebForms.PageRequestManager.getInstance().add_pageLoaded(endRequestHandler);
But I made no progress.
I've also tried to use the body tag, but still no joy.
Can please somebody tell me what I'm doing wrong?
Thanks.