2 ms·
Just to follow up, you can use our /scrape API to do this: curl -X POST \ https://chrome.browserless.io/scrape https://chrome.browserless.io/scrape \ -H 'C
by mrskitch 7y ago
Just to follow up, you can use our /scrape API to do this:
curl -X POST \
https://chrome.browserless.io/scrape https://chrome.browserless.io/scrape \
-H 'Content-Type: application/json' \
-d '{
"url": "https://reddit.com/" https://reddit.com/",
"elements": [{
"selector": "img"
}]
}'
This will get all the <img> tags on a page and return their attributes (which includes their sources). If you wanted to do scripts as well, just add a new object to the elements array with the "selector" of "script".