Running scripts in an ajax-loaded page fragment

前端 未结 4 1752
谎友^
谎友^ 2021-01-23 06:40

My web app dynamically loads sections of its UI with jquery.ajax. The new UI sections come with script though. I\'m loading them as such:

Use...



        
4条回答
  •  盖世英雄少女心
    2021-01-23 07:25

    Using

    $(function);

    will make the function you pass to jQuery to be run after the fragment is inline on the page. I found it in ASP.NET Ajax partial postback and jQuery problem after looking at your question.

提交回复
热议问题