Scraping and filtering dates

Hi all!

I want to scrape prices from this website, but when I filter dates I do not get a new link, so I dont know how to make the scraper filter the dates for me automatically (in this case I'd want Nov 27 to Dec 28). Can you please help? I've been half the day reading and trying but cant manage to do it

Thanks a lot!

@timon10z Greetings! It seems as if it is achievable by using several element click selectors.

Sitemap example:

{"_id":"ukio-filter-test","startUrl":["https://ukio.com/properties/madrid"],"selectors":[{"clickElementSelector":"button[width=\"auto\"]:contains(\"Dates\")","clickElementUniquenessType":"uniqueCSSSelector","clickType":"clickOnce","delay":1200,"discardInitialElements":"do-not-discard","id":"click-1","multiple":true,"parentSelectors":["_root"],"selector":"body","type":"SelectorElementClick"},{"clickElementSelector":"div[class*=\"styles__MiddleContainer\"] [aria-labelledby*='first-month'] div:nth-of-type(1) button:contains(\"27\")","clickElementUniquenessType":"uniqueCSSSelector","clickType":"clickOnce","delay":2000,"discardInitialElements":"do-not-discard","id":"click-2","multiple":true,"parentSelectors":["_root"],"selector":"body","type":"SelectorElementClick"},{"clickElementSelector":"div[class*=\"styles__MiddleContainer\"] div[aria-labelledby*='second-month'] button:contains(\"28\")","clickElementUniquenessType":"uniqueCSSSelector","clickType":"clickOnce","delay":2000,"discardInitialElements":"do-not-discard","id":"click-3","multiple":true,"parentSelectors":["_root"],"selector":"body","type":"SelectorElementClick"},{"clickElementSelector":"[class*=\"styles__FooterButtonsContainer\"] button:contains(\"Apply\")","clickElementUniquenessType":"uniqueText","clickType":"clickOnce","delay":2000,"discardInitialElements":"do-not-discard","id":"click-4","multiple":true,"parentSelectors":["_root"],"selector":"body","type":"SelectorElementClick"},{"id":"wrapper","multiple":true,"parentSelectors":["_root"],"selector":"a[class*=\"property_card__InnerContainer\"]","type":"SelectorElement"},{"id":"name","multiple":false,"parentSelectors":["wrapper"],"regex":"","selector":"div[class*=\"property_card_primary_info__FirstColumnPrimary\"]","type":"SelectorText"}]}

2 Likes

Oh this is amazing, thanks a lot! I was trying to make it click too but couldnt figure out how.
I am having one more issue though, the scraped results should be showing 8 rows, but only showing 6, my guess is that I need the page to scroll down to check for the last two containers. Could you please include this? Im also trying myself, maybe i can figure it out (and maybe not)

Thanks a lot again

EDIT: I made it!! Nevermind!! And thanks again, super helpful!

Are you selecting a specific date or only results that have a date available?
If you don't mind, can you share your sitemap? I'm trying to learn based on examples similar to yours.

Never mind my question, I see that you are selecting the class styles and buttons containing the values.
This helps a lot.
If you can, please share your final sitemap. The above is a great example to build from.
Thank you,

There you go:

{"_id":"ukio_test","startUrl":["https://ukio.com/properties/madrid"],"selectors":[{"id":"click-1","parentSelectors":["_root"],"type":"SelectorElementClick","clickElementSelector":"button[width="auto"]:contains("Dates")","clickElementUniquenessType":"uniqueCSSSelector","clickType":"clickOnce","delay":1200,"discardInitialElements":"do-not-discard","multiple":true,"selector":"body"},{"id":"click-2","parentSelectors":["_root"],"type":"SelectorElementClick","clickElementSelector":"div[class*="styles__MiddleContainer"] [aria-labelledby*='first-month'] div:nth-of-type(1) button:contains("27")","clickElementUniquenessType":"uniqueCSSSelector","clickType":"clickOnce","delay":2000,"discardInitialElements":"do-not-discard","multiple":true,"selector":"body"},{"id":"click-3","parentSelectors":["_root"],"type":"SelectorElementClick","clickElementSelector":"div[class*="styles__MiddleContainer"] div[aria-labelledby*='second-month'] button:contains("28")","clickElementUniquenessType":"uniqueCSSSelector","clickType":"clickOnce","delay":2000,"discardInitialElements":"do-not-discard","multiple":true,"selector":"body"},{"id":"click-4","parentSelectors":["_root"],"type":"SelectorElementClick","clickElementSelector":"[class*="styles__FooterButtonsContainer"] button:contains("Apply")","clickElementUniquenessType":"uniqueText","clickType":"clickOnce","delay":2000,"discardInitialElements":"do-not-discard","multiple":true,"selector":"body"},{"id":"wrapper","parentSelectors":["_root"],"type":"SelectorElementScroll","selector":"a[class*="property_card__InnerContainer"]","multiple":true,"delay":2000,"elementLimit":500},{"id":"name","parentSelectors":["wrapper"],"type":"SelectorText","selector":"div[class*="property_card_primary_info__FirstColumnPrimary"]","multiple":false,"regex":""}]}

1 Like

@ViestursWS sorry to bother you, but I do have another 2 questions (final)

  1. Once I filter as you showed me, I am trying to open each pop up link, filter the dates again and get information from there (the outcome price). I thought I had it with your example but when I scrape it opens all the pop ups but wont show result and I also dont see each pop up filtering the dates.
  2. Also, because its pop up links, is there any way to prevent my browser from opening all of them?

Thanks again!

EDIT: Took me 4 hours but I MANAGED!!