HTML <form> processing

In this section, we will be handling form processing or form submission in order to search for an activity from http://toscrape.com (ViewState). ViewState is an AJAX-based filter form.

This particular form submission is performed in multiple steps with the help of AJAX (https://www.w3schools.com/js/js_ajax_intro.asp). For more information on AJAX, please visit W3Schools AJAX:

http://toscrape.com with various endpoints in the Quotes section

Let's set up the code. The pyquery and requests libraries need to be imported and the required URLs need to be collected so that they can be used. The processRequests() function, ...

Get Hands-On Web Scraping with Python now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.