samcro 2 Posted June 18, 2013 Report Share Posted June 18, 2013 Hi guys, so I've been messing with this for the last hour or so and am drawing a blank. I have scraped a section of a page and have loaded that section with the load html command. The result looks like this: http://website.com/link1 http://website.com/link2 http://website.com/link2 http://website.com/link2 http://website.com/link3 http://website.com/link4 What I need is to extract http://website.com/link2 but only 1 time and save it to a variable. Not sure what I should do. Any help would be appreciated. Thanks, - samcro Quote Link to post Share on other sites
VaultBoss 310 Posted June 18, 2013 Report Share Posted June 18, 2013 If it is scraped multiple times, just add that url to a list with the advanced option set to "Delete" duplicates (which it is so by default anyway) and you'll end up with a list that contains the url only once. Quote Link to post Share on other sites
UBotDev 276 Posted June 18, 2013 Report Share Posted June 18, 2013 If that URL doesn't have unique identifier, you can maybe use "$element offset" or you could try adding all scraped URL's in the list and loop through until you find the right one. Quote Link to post Share on other sites
samcro 2 Posted June 18, 2013 Author Report Share Posted June 18, 2013 Thanks for the suggestions guys, finally got it to work! 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.