Joel, Check out the LiveQuery plugin. It will handle the binding of the newly loaded elements for you automatically. So instead of including a new, redundant <script> element within each loaded HTML fragment (or rolling your own recursive binding functions), you can just do it once right on the main page and be done with it:
$(function(){ $('a').livequery('click', function(){ $(this).parents('.cell').load('load.html'); }); }); HTH, Jason On Oct 23, 6:17 pm, Joel S <[EMAIL PROTECTED]> wrote: > Thanks Alex > > Yes, I'm aware that I'm reloading some jQuery each time the page loads > (or reloads) in the DIV, but I don't know how else to get the jQuery > functionality within the loaded pages, since the loaded pages happen > after the main page's $(document).ready(function()... calls the > initial jQuery code. > > Any ideas, anybody? > > Thanks, > -Joel > > On Oct 23, 3:14 am, dehneg <[EMAIL PROTECTED]> wrote: > > > Hi Joel, > > > Very strange. > > I am very new with jQuery so I can not help you. > > But using firegug I can see that by clicking to load you are loading > > hundreds times the page. > > Hope this can help, > > > Alex > > > On Oct 23, 12:02 am, Joel S <[EMAIL PROTECTED]> wrote: > > > > Hi all > > > > I'm fairly new to jQuery, but have been playing with it for a couple > > > months. This is my first post here. > > > > I've got a page with a <table> where each cell has a div that gets > > > reloaded using load(). Each page that gets loaded into its cell also > > > needs to be able to reload -- preferably multiple/infinite times. > > > > What I'm finding, however, is that after a few loads, the performance > > > degrades pretty significantly. Is this an unavoidable side-effect of > > > reloading jquery multiple times on the same page? Or is there a > > > better way to do this so that this doesn't happen? > > > > I searched this list and found a thread from Sept '06 that said: > > > "multiple HTTP-Requests <snip> increases the overhead." Is that what > > > I'm up against? > > > > WHAT I'VE GOT: > > > - On my main page: > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > > > $(document).ready(function() { > > > $('a').click(function(){ > > > $(this).parents(".cell").load("load.html"); > > > });}); > > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > > > > - My called/loaded page in its entirety is this: > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > > > <p><a href="#">LOADED page</a></p> > > > <script type="text/javascript" charset="utf-8"> > > > $('a').click(function(){ > > > $(this).parents(".cell").load("load.html"); > > > }); > > > </script> > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > > > > I've got a demo page if that would be helpful, at: > > > jsfmp<dotcom>/jquery/ajaxtable.html > > > > TIA, > > > -Joel