I'm admittedly new to JQuery, although I'm rather experienced
javascript programmer.

I have an application which uses JQuery to load an HTML page through
AJAX. I have logic, implemented as javascript functions, inside the
page being loaded which I'd like to invoke after the page load is
complete and the DOM is updated w/ all the HTML tags inside that page.
I can't figure out how to do this.

-I've tried using $('document').ready(...) within the loaded page; it
gets invoked before the DOM is accessible.
-I've tried using $(window).bind("load", function () { within the
loaded page; it never gets invoked.
-I can't figure out how to make a call from the loading page into the
loaded page; everything I try it seems the script functions from the
loaded page are not known by the DOM.

Does anyone have a good suggestion for how best to set this up?

Currently the loading page looks something like this:

    $("#myWin").load(url, function() {
        window.onPageLoad();  // this fails w/ object expected, or
objec does not suppor this method JS errors
     });


within the page being loaded I have something like this:
     function onPageLoad() {
        ....
     }

any help would be appreciated.

-Gregg

Reply via email to