Home  >  Q&A  >  body text

python爬虫 - python urllib中创建request时应直接传入post data还是在urlopen时再传入post data

文档里看到二者都可传入data,urlopen也支持request对象或者url

PHPzPHPz2740 days ago823

reply all(1)I'll reply

  • 巴扎黑

    巴扎黑2017-04-18 10:10:38

    If your request can be reused, it is better to pass it in the request. In fact, there is not much difference.

    reply
    0
  • Cancelreply