Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Hands-On Web Scraping with Python

You're reading from   Hands-On Web Scraping with Python Perform advanced scraping operations using various Python libraries and tools such as Selenium, Regex, and others

Arrow left icon
Product type Paperback
Published in Jul 2019
Publisher Packt
ISBN-13 9781789533392
Length 350 pages
Edition 1st Edition
Languages
Arrow right icon
Author (1):
Arrow left icon
Anish Chapagain Anish Chapagain
Author Profile Icon Anish Chapagain
Anish Chapagain
Arrow right icon
View More author details
Toc

Table of Contents (16) Chapters Close

Preface 1. Section 1: Introduction to Web Scraping FREE CHAPTER
2. Web Scraping Fundamentals 3. Section 2: Beginning Web Scraping
4. Python and the Web – Using urllib and Requests 5. Using LXML, XPath, and CSS Selectors 6. Scraping Using pyquery – a Python Library 7. Web Scraping Using Scrapy and Beautiful Soup 8. Section 3: Advanced Concepts
9. Working with Secure Web 10. Data Extraction Using Web-Based APIs 11. Using Selenium to Scrape the Web 12. Using Regex to Extract Data 13. Section 4: Conclusion
14. Next Steps 15. Other Books You May Enjoy

Overview of regular expressions

Regular expressions are used to match patterns found in text or strings. Regex can be used for testing and finding patterns as desired against text or web content. Regex contains various ways to define patterns and special notations, such as escape codes to apply some predefined rules. For more information on Regex, please refer to the Further reading section.

There are various cases where Regex can be quite effective and quick for obtaining the desired results. Regex can be applied to content (text or web sources) alone and can be used to target specific information patterns that aren't easily extractable while using XPath, CSS selectors, BS4, PyQuery, and so on.

Sometimes, cases may arise that will demand Regex and XPath or CSS selectors to be used together in order to obtain the desired output. This output can then be tested using Regex...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime