Calling a jQuery function inside html return from an AJAX call

前端 未结 6 2203
梦毁少年i
梦毁少年i 2020-12-02 17:45

I am working on a web page that is using jQuery. I have an Ajax call that gets data from the server and updates a div. Inside that data there is a jQuery function, but the f

6条回答
  •  遥遥无期
    2020-12-02 18:23

    have you tried Sys.WebForms.PageRequestManager.add_endRequest method?

        $(document).ready(function()
        {
            Sys.WebForms.PageRequestManager.getInstance().add_endRequest(endRequestHandler);           
        }
        );
        function endRequestHandler(sender, args)
        {
            // whatever
        }
    

提交回复
热议问题