Author

Topic: What is wrong with this JavaScript code ? (Read 599 times)

hero member
Activity: 513
Merit: 509
February 06, 2014, 03:27:25 PM
#4
In line 167 you have a timeout of 100milliseconds, the API states though that you should limit your queries to once every 10 seconds,
you should change the timeout from '100' to '10000' (10000milliseconds -> 10 seconds)

Just to be on the save side, I'd change it to 11000 or 12000

Not sure if that was all, but that's what cought my attention at the first glance Wink - hope this helps!

Thanks for that, didn't know about the 10 seconds minimum for queries. I changed it for 12 sec like you said. Might be it ! Smiley

Thanks again ! Smiley
sr. member
Activity: 434
Merit: 250
February 06, 2014, 03:26:23 PM
#3
yep, pretty much that.
Also the fact that you don't wait for your request to finish before sending another one.
you can handle GET requests way more easier using Jquery and you can use a callback when you get a response.
That would be a better way to make an asynchronous recursive function like the one you want.
newbie
Activity: 55
Merit: 0
February 06, 2014, 03:22:34 PM
#2
In line 167 you have a timeout of 100milliseconds, the API states though that you should limit your queries to once every 10 seconds,
you should change the timeout from '100' to '10000' (10000milliseconds -> 10 seconds)

Just to be on the save side, I'd change it to 11000 or 12000

Not sure if that was all, but that's what cought my attention at the first glance Wink - hope this helps!
hero member
Activity: 513
Merit: 509
February 06, 2014, 03:04:58 PM
#1
Hi everyone !

What is wrong in this code that always make my IP banned from blockchain.info ?

http://pastebin.com/TPFiiygQ

Thanks for your help ! Smiley
Jump to: