Jump to content
UBot Underground

How can I trim a href after scraping the href's from a page?


Recommended Posts

here's my code at the moment,

 

add list to list(%scrapes$list from text($scrape attribute(<data-subjectid=w"*">"href"), $new line), "Delete""Global")

 

 

at the moment, it scrapes the href from the page, and it looks like this:

 

/wishlist/and?subjectId=20059

/wishlist/and?subjectId=35252

/wishlist/and?subjectId=54554

 

etc...

 

how do I remove everything before the numbers, so all i'm left with is this, each on a separate line, eg:

20059

35252

54554

 

cheers

Link to post
Share on other sites

use replace from text functions, replace /wishlist/and?subjectId= replace with nothing

 

 

----------

add list to list(%scrapes$list from text($replace($scrape attribute(<data-subjectid=w"*">"href"), "/wishlist/and?subjectId="$nothing), $new line), "Delete""Global")

-------

this should work

  • Like 1
Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...