1
I’m creating a way to extract data from Twitter without being quoted the values of their API. The best way I found was using the widget that they provide (and that has no quota) and from its loading I "take the information" and treat them.
My problem is that I am unable to think of a way to make the page check if there is a tag in the element body
that Twitter creates after its upload [data-twttr-rendered=true]
.
I tried to make a setInterval
analyzing whether this exists and, if it exists, it executes a function and how callback already runs its own clearInterval
thus:
var twitter = setInterval(function(){
if($('body[data-twttr-rendered=true]').length != 0){
page.twitter.mutage(function(){clearInterval(twitter)});
}
},1000);
The problem that by executing such code I can bug the DOM and block the entire site...
Someone there has a better answer for me please?
What is the function for
page.twitter.mutage
? And why cancel the break?– bfavaretto