In this tutorial, we are going to show you how to scrape the leads from Yellowpages.
For Yellowpages, you could visit our easy-to-use "Task Template" on the main screen of the Octoparse scraping tool. All you need is to type in several parameters and the task is ready to go. For further details, you may check it out here: Task Templates
For this example, we will use the URL below in order to scrape data such as title, address, telephone and etc.
Here are the main steps in this tutorial [Download task file here :]
- "Go To Web Page" - to open the target web page
- Create a pagination - to scrape all data from multiple pages
- Build a "Loop Item" - to Loop click into each item on each list
- Extract data - to select data you need to scrape
- Run extraction - to run your task and get data
1. "Go To Web Page" - to open the target page
- Click "+ Task" to start a new task with Advanced Mode
- Paste the URL into the "Website" box
- Click "Save URL" to move on
- Scroll down the page and click the next page button "Next"
- Click "Loop click next page" on the "Action Tips"
- Click "Go To Web Page" to return to the first page
When extracting data throughout multiple pages, you should always begin your task building on the first page.
- Click "Pagination"
- Click the title of the first list on the current page
- Click "Select all" on the Action Tips panel
- Click "Loop click each element"
4. Extract data - to select data you need to scrape
- Click on the data you need on the page
- Select "Extract text of the selected element" on the "Action Tips"
- Click "Add predefined field " and choose "Add current page information" and select "Web page URL" (Optional)
- Rename the fields by selecting from the pre-defined list or inputting on your own
5. Run extraction - to run your task and get data
- Click "Start Extraction" on the upper left side
- Select "Local Extraction" to run the task on your computer, or select "Cloud Extraction" to run the task in the Cloud (for premium users only)
Here is the sample output: