[Resolved] Block content

Discussion in 'Custom Filters' started by MrSmithr, Aug 15, 2017.

  1. MrSmithr

    MrSmithr New Member

    Joined:
    Aug 15, 2017
    Messages:
    4
    Hi,

    I'm trying to block content on a website on mobile. I have on my desktop Adblock filters in place which work but on adguard for mobile I can't seem to get them to work even after reading how to create the custom filters.

    Website: http://www.preloved.co.uk

    Adblock filters:
    Code:
    ##li[id^="search-text-ad"]
    ##nav[id^="page-floating-cta-sell"]
    I would like to completely remove the elements from the page, however the elements are only displayed on mobile and not tablet/desktop.

    [​IMG]

    I hope this is of help and thank you in advance.
     
  2. MrSmithr

    MrSmithr New Member

    Joined:
    Aug 15, 2017
    Messages:
    4
    I have managed to create successful filters, just had to make minor adjustments. :)

    Code:
    ||preloved.co.uk##li[id^="search-text-ad"]
    ||preloved.co.uk##nav[id*="page-floating-cta-sell"]
    
    The first filter removes the adverts placed in the search results and the second filter removes the ad at the bottom.
     
  3. Alex302

    Alex302 Filters Developer Staff Member Administrator

    Joined:
    Jul 20, 2012
    Messages:
    24,721
    Please provide full URL of that page.
     
  4. MrSmithr

    MrSmithr New Member

    Joined:
    Aug 15, 2017
    Messages:
    4
    Thank you for the reply.

    It is within the adverts page after making a search which requires an account but I managed to create a successful filter outlined in my previous reply.

    Many thanks
     
  5. Alex302

    Alex302 Filters Developer Staff Member Administrator

    Joined:
    Jul 20, 2012
    Messages:
    24,721
    The rules are invalid.
    || are unnecessary in element hiding rules.
     
  6. MrSmithr

    MrSmithr New Member

    Joined:
    Aug 15, 2017
    Messages:
    4
    They worked for me. I'm not entirely sure what the "||" represents but I'm happy that they work. Adguard filter doesn't specify whether the filter is invalid/valid so I just typed it in and tested, it worked.