smoulderlife 0 Posted September 10, 2015 Report Share Posted September 10, 2015 Hi All, From the below html want to just scrape "?cat=dra_896". How to do this ?. ---------------------------------------------------------<a class="cat-filter" data-url="?cat=dra_896">Dragon </a>----------------------------------------------------------If someone wondering why do i need this ?, Just a Background, On the target website this is a category filter, when ever you click this element, the link will reflect this content with different data on the page loaded accordingly, So i want to store this values in a list. Please let me know if you need more details. Have tried all the different things but no luck. Appreciate help from the community. Thanks. Quote Link to post Share on other sites
Brutal 164 Posted September 11, 2015 Report Share Posted September 11, 2015 Regex would be easiest <<== Click it. Quote Link to post Share on other sites
v_ladimir 2 Posted September 11, 2015 Report Share Posted September 11, 2015 set(#cat,$find regular expression("","(?<=url\\=).*(?=\\>)"),"Global")regex:(?<=url\=).*(?=\>) Quote Link to post Share on other sites
smoulderlife 0 Posted September 11, 2015 Author Report Share Posted September 11, 2015 Thanks for both Software and v_ladimir, It did the trick. Here is what i did as a reference for others, in case facing the same issue. add list to list(%cat,$find regular expression($document text,"(?<=data-url\\=\").*(?=\\\">)"),"Delete","Global") 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.