Process a continuous stream of JSON

前端 未结 4 1329
耶瑟儿~
耶瑟儿~ 2020-11-30 19:16

The (now defunct) page http://stream.twitter.com/1/statuses/sample.json used to return a continuous and endless stream of JSON data.

I\'d like to process it using jQ

4条回答
  •  天涯浪人
    2020-11-30 20:07

    The url you have specified in your question sends a JSON response stream. Due to cross domain security restrictions in browsers you cannot access it using javascript. You will need to implement a bridge server side script on your server which you could poll at regular intervals using AJAX requests or host your site on twitter.com. The first seems more feasible.

提交回复
热议问题