Link to home
Start Free TrialLog in
Avatar of xenium
xenium

asked on

How to scrape non-visible page info using IMPORTXML

hi,

I need to get a list of SKU codes for all types of peas sold online, I can query this online eg:

https://www.ocado.com/webshop/getSearchProducts.do?clearTabs=yes&isFreshSearch=true&chosenSuggestionPosition=&entry=peas

I can scrape the product info with XML:
//*[@id="js-productPageFops"]/ul/li[1]

switch [1] with item number.

How can I do the same for the SKU code which is not visible on the page but can be seen in the code, eg:
User generated image
Thanks!


PS Incidentally the website's policy on scraping: https://www.ocado.com/webshop/scontent/termsOfUse
"4.6 You may only scrape the Website on the basis that by doing so you are permitting us to scrape any website owned or controlled by you."
Avatar of xenium
xenium

ASKER

PS I only need a list of the SKU codes returned by the search, I don't need the matching descriptions
ASKER CERTIFIED SOLUTION
Avatar of ste5an
ste5an
Flag of Germany image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of xenium

ASKER

Excellent thank you. I'm new to XML so this is really useful.