Page 1 of 1

Need help with regexp

Posted: Sun Mar 13, 2016 8:17 am
by drloser
Hello,

I'm trying to filter this kind of stuff:

senscritique.com##.demh-container.demh185-product
senscritique.com##.demh-container.demh187-product
senscritique.com##.demh-container.demh188-product
senscritique.com##.demh-container.demh189-product
senscritique.com##.demh-container.demh190-product
senscritique.com##.demh-container.demh191-product
...

I tried to use the below regexp, but it's not working:

senscritique\.com\#{2}\.demh-container\.demh\d+-product

Any idea?

Re: Need help with regexp

Posted: Sun Mar 13, 2016 8:50 am
by mapx
you could try:

Code: Select all

senscritique.com##div[class^="demh-container.demh"]
or

Code: Select all

senscritique.com##div[class^="demh-container.demh"][class$="-product"]
see en/filters#elemhide_attributes

Re: Need help with regexp

Posted: Sun Mar 13, 2016 10:53 am
by drloser
It's not working... I will have a look at that link.

Re: Need help with regexp

Posted: Sun Mar 13, 2016 11:41 am
by mapx
provide the specific page, explain what elements in the page you want to hide

Re: Need help with regexp

Posted: Tue Mar 15, 2016 10:46 am
by drloser
It's the large banner which appears on top of this page by example. You can't miss it:
http://www.senscritique.com/series

Re: Need help with regexp

Posted: Tue Mar 15, 2016 10:54 am
by mapx
test this filter

Code: Select all

senscritique.com##[class^="demh-container demh"][data-sc-tyson-element-event="product-click"]
however if you use firefox, install EHH (element hiding helper) to create your own hiding filters, use it in advanced view, you'll can edit your hiding filters (keeping the stable part)

Re: Need help with regexp

Posted: Wed Mar 16, 2016 7:39 am
by drloser
(I use Chrome.)

This last filter seems to be working perfectly fine. Thanks a lot.