Hi.
I would like to load a page with jquery .load, and then do some changes on loaded page with some jquery functions.
so it will look like this:
Code:
$(“#tempcont”).load(target, function() {
$(“#center-inner .maincontent”).css(‘display’, ‘none’);
$(“#center-inner .maincontent”).fadeIn();
});
But i need to do the same thing in other places (do the stuff on loaded content), so I was wondering, maybe i will make a function:
Code:
$.fn.doactions = function() {
$(“#center-inner .maincontent”).css(‘display’, ‘none’);
$(“#center-inner .maincontent”).fadeIn();
});
}
and then call it when i need it:
but it seems not to work (i got no errors, but actions are not working).
Where is the error?
Thanks in advice.