Anybody ? Simple HREF Grab

How can i just get the HREF from this TAG

Iv tried and tried all options. there must be a way but i cant for the life of me grab the URL

Needs to include the full url including magnet:? +++

a class="elementor-button elementor-button-link elementor-size-xs" href="magnet:?xt=urn:btih:6E57E2DC666CE7928C23347F5CEF7D029F37B070&tr=http%3A%2F%2Fbt4.t-ru.org%2Fann%3Fmagnet&dn=dSONIQ%20-%20Realphones%20v1.8.193%20SAL%2C%20VST%2C%20VST3%2C%20AAX%20x64%20%5B31.12.2023%5D"

Hi, this should work with the Link selector type. Could you please provide your sitemap?

1 Like

Currently im just grabbing the HTML but i need only the magnet url for my database

{"_id":"audiostorrentandgenresoftware","startUrl":["https://audiostorrent.com/page/[0-285]"],"selectors":[{"id":"linker","linkType":"linkFromHref","multiple":false,"parentSelectors":["wrapper"],"selector":".entry-title a","type":"SelectorLink"},{"id":"title","multiple":false,"parentSelectors":["linker"],"regex":"","selector":"h1","type":"SelectorText"},{"id":"image","multiple":false,"parentSelectors":["linker"],"selector":"img.attachment-large","type":"SelectorImage"},{"id":"file info","multiple":false,"parentSelectors":["linker"],"regex":"","selector":"ul:nth-of-type(2)","type":"SelectorText"},{"id":"info","multiple":false,"parentSelectors":["linker"],"regex":"","selector":".elementor-element-32b37555 div.elementor-widget-container","type":"SelectorText"},{"id":"catagory","multiple":false,"parentSelectors":["linker"],"regex":"","selector":"div.cat-links","type":"SelectorText"},{"id":"dateadded","multiple":false,"parentSelectors":["linker"],"regex":"","selector":"a time.entry-date","type":"SelectorText"},{"id":"video","multiple":false,"parentSelectors":["linker"],"regex":"https://www.youtube.com/embed/[^\" ]+","selector":"div.articletxt","type":"SelectorHTML"},{"id":"soundcloud","multiple":false,"parentSelectors":["linker"],"regex":"https://w.soundcloud.com/player/[^\" ]+","selector":".soundcloudclass","type":"SelectorHTML"},{"id":"mp3","multiple":false,"parentSelectors":["linker"],"regex":"https://cdn-prd.sounds.com[^\" ]+","selector":".dleaudioplayer","type":"SelectorHTML"},{"id":"download","multiple":false,"parentSelectors":["linker"],"regex":"","selector":"div.elementor-button-wrapper","type":"SelectorHTML"},{"id":"wrapper","multiple":true,"parentSelectors":["_root"],"selector":"article","type":"SelectorElement"}]}

The sitemap code is not valid. Please post it as Preformatted text.

code

ok have done so. thank you

Did you try the Element attribute type? And scrape the href attribute?

image

I have tried everything this is why im asking for someone with some knowledge to help.

Here is the sitemap with the selector as Element attribute type. It scrapes the href value. Is this the desired result?

{"_id":"audiostorrentandgenresoftware","startUrl":["https://audiostorrent.com/page/[0-1]"],"selectors":[{"id":"linker","linkType":"linkFromHref","multiple":false,"parentSelectors":["wrapper"],"selector":".entry-title a","type":"SelectorLink"},{"id":"title","multiple":false,"parentSelectors":["linker"],"regex":"","selector":"h1","type":"SelectorText"},{"id":"image","multiple":false,"parentSelectors":["linker"],"selector":"img.attachment-large","type":"SelectorImage"},{"id":"file info","multiple":false,"parentSelectors":["linker"],"regex":"","selector":"ul:nth-of-type(2)","type":"SelectorText"},{"id":"info","multiple":false,"parentSelectors":["linker"],"regex":"","selector":".elementor-element-32b37555 div.elementor-widget-container","type":"SelectorText"},{"id":"catagory","multiple":false,"parentSelectors":["linker"],"regex":"","selector":"div.cat-links","type":"SelectorText"},{"id":"dateadded","multiple":false,"parentSelectors":["linker"],"regex":"","selector":"a time.entry-date","type":"SelectorText"},{"id":"video","multiple":false,"parentSelectors":["linker"],"regex":"https://www.youtube.com/embed/[^\" ]+","selector":"div.articletxt","type":"SelectorHTML"},{"id":"soundcloud","multiple":false,"parentSelectors":["linker"],"regex":"https://w.soundcloud.com/player/[^\" ]+","selector":".soundcloudclass","type":"SelectorHTML"},{"id":"mp3","multiple":false,"parentSelectors":["linker"],"regex":"https://cdn-prd.sounds.com[^\" ]+","selector":".dleaudioplayer","type":"SelectorHTML"},{"extractAttribute":"href","id":"download","multiple":false,"parentSelectors":["linker"],"selector":"div.elementor-button-wrapper a","type":"SelectorElementAttribute"},{"id":"wrapper","multiple":true,"parentSelectors":["_root"],"selector":"article","type":"SelectorElement"}]}

ok thank you. i finally after analysing your code realised there is a dropdown menu that offers href.