Problem with http GET request on node js

后端 未结 2 752
悲&欢浪女
悲&欢浪女 2021-02-15 13:24

Im writing an http client to read from facebook using node.js and using the following code:

var http = require(\'http\');

var options = {
  host: \'www.fb.com\'         


        
2条回答
  •  小鲜肉
    小鲜肉 (楼主)
    2021-02-15 13:58

    This dosent seem to be a bug of node.js I made a request to fb.com in curl and I got the same redirect.

    It probably makes that decision based on the user agent... maybe you can use the user agent of a browser :D

提交回复
热议问题