I would not activate them with an interval like you are trying, but rather immediately when creating the new item, just call a function like this one function activate_timeago(el){ $(el). Each(function(){ if (!$(this). HasClass('processed')){ $(this).timeago(); $(this).
AddClass('processed'); } }); } after the ajax callback for fetching new items is done, just call: var elements = $('#container . New'); activate_timeago(elements) edit just so there is no confusion, the $('#container . New') selector is not default jQuery new is a css class like any other class, you could add the class new to your elements when you do the ajaxcall, or you could select them in another way since you probably have just added them to the DOM in your ajax callback you already might have them available in an array end edit but, if you really want to continue on the interval part use this: function activate_timeago(){ setInterval(function(){ $('.
Timeago:not(.processed)'). Each(function(){ $(this).timeago(); $(this). AddClass('processed'); } }); },60000); } this function you'd only call once at the page load, downside of option two, they are not made into timeago immediately, but only after the next time the interval hits.
I would not activate them with an interval like you are trying, but rather immediately when creating the new item, just call a function like this one function activate_timeago(el){ $(el). Each(function(){ if (!$(this). HasClass('processed')){ $(this).timeago(); $(this).
AddClass('processed'); } }); } after the ajax callback for fetching new items is done, just call: var elements = $('#container . New'); activate_timeago(elements); edit just so there is no confusion, the $('#container . New') selector is not default jQuery, new is a css class like any other class, you could add the class new to your elements when you do the ajaxcall, or you could select them in another way since you probably have just added them to the DOM in your ajax callback you already might have them available in an array ... end edit but, if you really want to continue on the interval part use this: function activate_timeago(){ setInterval(function(){ $('.
Timeago:not(.processed)'). Each(function(){ $(this).timeago(); $(this). AddClass('processed'); } }); },60000); } this function you'd only call once at the page load, downside of option two, they are not made into timeago immediately, but only after the next time the interval hits.
I didn't know about the . New stuff, that's cool – madprops Sep 15 at 20:26 I did add some extra clarification in an Edit to my answer, because I thought it could be misunderstood :) – Sander Sep 16 at 6:29.
Ok this seems to work function activate_timeago(){ $('. Timeago'). Each(function(){ var $this = $(this); if ($this.
Data('active')! ='yes'){ $this.timeago(). Data('active','yes'); } }); setTimeout(activate_timeago, 60000); } Thanks to eddiemonge on #jquery.
This is a good solution (if you don't mind the fact that your abbr's will only be switched into timeago once every 60 seconds), for real time timeago as soon as your elements are loaded, you could follow my first solution. Your choice really... – Sander Sep 15 at 19:38.
I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.