https://github.com/rggh/scrapy12
cookpad
https://github.com/rggh/scrapy12
cookpad infinite-scroll scrapy-spider
Last synced: about 1 year ago
JSON representation
cookpad
- Host: GitHub
- URL: https://github.com/rggh/scrapy12
- Owner: RGGH
- Created: 2020-11-25T17:51:28.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2020-11-25T18:08:40.000Z (over 5 years ago)
- Last Synced: 2025-02-02T03:32:33.087Z (over 1 year ago)
- Topics: cookpad, infinite-scroll, scrapy-spider
- Language: Python
- Homepage:
- Size: 6.84 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Scrapy12
## Scrapy : cookpad.com/uk
### Infinite scroll pagination with a twist
if response.xpath("//a/@rel='next\'").get() == "1":
print("GET Next Page")
next_page = response.xpath('//a[@rel="next"]/@href').get()
yield response.follow(url=next_page,callback=self.parse)