Scrapy, hash tag on URLs

后端 未结 3 975
半阙折子戏
半阙折子戏 2020-12-21 05:10

I\'m on the middle of a scrapping project using Scrapy.

I realized that Scrapy strips the URL from a hash tag to the end.

Here\'s the output from the shell:<

3条回答
  •  無奈伤痛
    2020-12-21 06:08

    Actually, when entering that URL in a web browser, it will also only send the part before the hash tag to the web server. If the content is different, it's probably because there are some javascript on the page that - based on the content of the hash tag part - changes the content of the page after it has been loaded (most likely an XmlHttpRequest is made that loads additional content).

提交回复
热议问题