w14219 0 Posted November 25, 2012 Report Share Posted November 25, 2012 I am trying to make a YellowPages scrape to capture the following information into a csv file.Business NameAddressPhone Numberwebsite URL Issue I am having:Yellow Pages does not have all the information for each listing. When I scrape the page with Scrape Attribute, add item to List to List then save the table to a CSV file, everything gets out of line. The wrong address will be with the wrong business. I tried to do an if then statement with a condition for <div class="rank pin">:if <div class="rank pin"> then website, address, phone and business name to list "A"Else if <div class="rank"> then website, address, phone and business name to list "B" Yellow Pages has the information available (address, phone and business name) when <div class="rank pin">. I was trying to only capture the information if the <div class="rank pin"> is true. However, the if statement works for the entire page, not specific table space in the web page. help would be greatly appreciated. Thanks,mike Quote Link to post Share on other sites
Legend 181 Posted November 25, 2012 Report Share Posted November 25, 2012 Instead of scraping the page, you might want to click on each of the links and then scrape the information from their individual pages... I haven't looked but there is a good chance it is formatted in a more easily accessible format there... Quote Link to post Share on other sites
UBotBuddy 331 Posted November 25, 2012 Report Share Posted November 25, 2012 Did you look at these videos? http://ubottraining.com/?page_id=91 Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.