You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The HTML tags making up the "Recommended by Columbia" are embedded in the document, no need for javascript. Easy to find out, just put view-source:http://timesofindia.indiatimes.com/us-elections-2016/Obama-tells-Latin-America-and-world-Give-Trump-time-dont-assume-worst/articleshow/55523627.cms in address bar and search for "columbia" (inline javascript only makes them clickable).
Actually the filter suggested filter on EasyList forum works well, the random-class div containing the ads are pretty much always preceded by a style tag:
@gorhill As I posted in the first post, the above cosmetic filter works. I started this issue as I saw a lot of data being spent to load the ad images but as you posted above these ads can't seem to be blocked and the best we can do for now is hide them.
@okiehsch That does work for the ads in the articles but these Colombia ads are displayed all over this website without that background image and they do not get hidden. Like on the homepage: http://timesofindia.indiatimes.com
The same is true for ads on other websites in this ad network (owned by the publisher of these websites) which are displayed without that background picture. For example: http://navbharattimes.indiatimes.com/world/rest-of-europe/head-of-french-military-quits-after-row-with-emmanuel-macron/articleshow/59678633.cms
seems to work at http://navbharattimes.indiatimes.com/world/rest-of-europe/head-of-french-military-quits-after-row-with-emmanuel-macron/articleshow/59678633.cms on my end, I hope, as I can't read hindi.
The previous filter covered all these ads on the different websites of the publisher. A similar solution would be really beneficial here. There are quite a few websites using these ads: AdguardTeam/AdguardFilters#4787
It would look the same, just in ES5. a.inject is not needed because scriptlets are already in page scope. a.on is just mapped to window.addEventListener.
Activity
gorhill commentedon Dec 27, 2016
Does this work?
uBlock-user commentedon Dec 27, 2016
No, infact blocking 3rd party content and inline script won't stop it either from appearing.
gorhill commentedon Dec 27, 2016
I noticed this afterward, the site use a cookie to not always serve the Columbia ads, this made me think the filter above worked.
I came up with this:
First one is uBO-specific, second one should also work for ABP.
uBlock-user commentedon Dec 27, 2016
How are they able to load even after inline-script and first party scripts are blocked ?
gorhill commentedon Dec 27, 2016
They are not loaded after, they are served as part of the document by the server.
uBlock-user commentedon Dec 27, 2016
So basically the script is fragmented and embedded as a part of the document and no longer a standalone js.
gorhill commentedon Dec 27, 2016
The HTML tags making up the "Recommended by Columbia" are embedded in the document, no need for javascript. Easy to find out, just put
view-source:http://timesofindia.indiatimes.com/us-elections-2016/Obama-tells-Latin-America-and-world-Give-Trump-time-dont-assume-worst/articleshow/55523627.cmsin address bar and search for "columbia" (inline javascript only makes them clickable).gorhill commentedon Dec 27, 2016
Actually the filter suggested filter on EasyList forum works well, the random-class div containing the ads are pretty much always preceded by a style tag:
So no need for any extended uBO syntax.
gotitbro commentedon Dec 29, 2016
@gorhill As I posted in the first post, the above cosmetic filter works. I started this issue as I saw a lot of data being spent to load the ad images but as you posted above these ads can't seem to be blocked and the best we can do for now is hide them.
gotitbro commentedon Jul 21, 2017
@gorhill @okiehsch The the filter suggested filter on the EasyList forum does not seem to be working anymore:
##style[type="text/css"] + div[class]I am again seeing the "Recommended by Colombia" ads.
Error URL:
http://timesofindia.indiatimes.com/world/europe/polish-parliament-adopts-contested-supreme-court-reform/articleshow/59686535.cms
okiehsch commentedon Jul 21, 2017
The first one suggested by gorhill still works for me
gotitbro commentedon Jul 21, 2017
@okiehsch That does work for the ads in the articles but these Colombia ads are displayed all over this website without that background image and they do not get hidden. Like on the homepage:
http://timesofindia.indiatimes.comSS: https://i.imgur.com/i3r2THZ.png
The same is true for ads on other websites in this ad network (owned by the publisher of these websites) which are displayed without that background picture. For example:
http://navbharattimes.indiatimes.com/world/rest-of-europe/head-of-french-military-quits-after-row-with-emmanuel-macron/articleshow/59678633.cmsokiehsch commentedon Jul 21, 2017
@gotitbro this
seems to work at
http://navbharattimes.indiatimes.com/world/rest-of-europe/head-of-french-military-quits-after-row-with-emmanuel-macron/articleshow/59678633.cmson my end, I hope, as I can't read hindi.gotitbro commentedon Jul 21, 2017
@okiehsch Thanks, those filters do work for the ads in the articles, the ads on the homepage are still visible: http://navbharattimes.indiatimes.com
The previous filter covered all these ads on the different websites of the publisher. A similar solution would be really beneficial here. There are quite a few websites using these ads:
AdguardTeam/AdguardFilters#4787
14 remaining items
jspenguin2017 commentedon Sep 4, 2017
As you scroll, more contents are loaded, so you need to keep scanning it...
okiehsch commentedon Apr 8, 2018
NanoAdblocker/NanoFilters#57
jspenguin2017 commentedon Apr 8, 2018
The script rule for reference:
Details
ghajini commentedon May 7, 2018
a PR for this would help a lot @jspenguin2017
jspenguin2017 commentedon May 7, 2018
I can PR if @gorhill accepts it.
I think he'll shake his head on the
setInterval.gotitbro commentedon May 27, 2018
@okiehsch Any plan on incorporating the Nano solution to the uBO filters?
okiehsch commentedon May 28, 2018
@gotitbro
jspenguin2017 already pinged gorhill, it's his decision.
gorhill commentedon May 29, 2018
How would a scriptlet look like? I would like to try it first on my side.
jspenguin2017 commentedon May 29, 2018
It would look the same, just in ES5.
a.injectis not needed because scriptlets are already in page scope.a.onis just mapped towindow.addEventListener.gotitbro commentedon Aug 16, 2018
@gorhill Can the Nano fix be added to uBO? Would be great if this issue can be solved.
jspenguin2017 commentedon Aug 18, 2018
uBO probably won't have it because it has a measurable performance impact.
I'm not too worried about that as Nano is intended to be for computers only (not for cell phones). I'm rolling an experimental port of the solution in ND:
NanoAdblocker/NanoFilters@4f4de6c
NanoAdblocker/NanoFilters@df8a96f
jspenguin2017 commentedon Oct 7, 2018
Can someone test whether this works? https://github.com/NanoAdblocker/NanoFilters/blob/master/NanoFiltersSource/NanoResources.txt#L67
mapx- commentedon Mar 13, 2019