Flash Ad Blocking
- JC
- Posts: 206
- Joined: November 4th, 2002, 7:39 pm
- Location: California
Flash Ad Blocking
I know it's been mentioned before, but it's this is the feature I would most like to see implemented, seeing as a good proportion of Ads nowadays are Flash ads.
- Immacolata
- Posts: 24
- Joined: November 5th, 2002, 12:37 am
- Location: Copenhagen, Denmark
- Contact:
-
- Posts: 1269
- Joined: November 5th, 2002, 7:32 am
- Location: PA
- Contact:
Flash Ad blocking
I posted this earlier, in the old forums. Right now it's more of a prototype of how I'd like to see this feature implemented. I know there's ongoing work for "per-site blocking of any mime type" - http://bugzilla.mozilla.org/show_bug.cgi?id=94035 but I think that's a lot of work, and not likely to be intuitive. I know personally that even though Moz/Phoenix has per-site image blocking, I still hardly ever use it, not to mention the fact that you'd have to enable it for every new site you come across.
I'm more interested in this bug: http://bugzilla.mozilla.org/show_bug.cgi?id=94035 . I hacked together a quick XUL/JS implementation, based on the banner blind source, to hide plugin content, and in its place display a button that says "click here to view". I think this would be the best way to implement this feature, since it doesn't require effort on the part of the user to hide the content, but only to view the content. This way the user gets to choose what plugin content they wish to view. The main problem with my hack implementation right now is that it hides everything after they've been loaded, which defeats the purpose of disabling flash to save bandwidth. I'm not sure what would be required to make that happen, but I'm looking into it.
Anyway, you can grab my little hack from http://ted.mielczarek.org/code/pluginask/pluginask.zip, and the README from http://ted.mielczarek.org/code/pluginask/README.txt
http://ted.mielczarek.org/code/pluginask/sshot.png shows what the code does, in a very uninteresting manner.
I'm more interested in this bug: http://bugzilla.mozilla.org/show_bug.cgi?id=94035 . I hacked together a quick XUL/JS implementation, based on the banner blind source, to hide plugin content, and in its place display a button that says "click here to view". I think this would be the best way to implement this feature, since it doesn't require effort on the part of the user to hide the content, but only to view the content. This way the user gets to choose what plugin content they wish to view. The main problem with my hack implementation right now is that it hides everything after they've been loaded, which defeats the purpose of disabling flash to save bandwidth. I'm not sure what would be required to make that happen, but I'm looking into it.
Anyway, you can grab my little hack from http://ted.mielczarek.org/code/pluginask/pluginask.zip, and the README from http://ted.mielczarek.org/code/pluginask/README.txt
http://ted.mielczarek.org/code/pluginask/sshot.png shows what the code does, in a very uninteresting manner.
-
- Posts: 1269
- Joined: November 5th, 2002, 7:32 am
- Location: PA
- Contact:
Bah
Fixed that 404'ed screenshot link.
In all its uninteresting glory: http://ted.mielczarek.org/code/pluginask/sshot.png
In all its uninteresting glory: http://ted.mielczarek.org/code/pluginask/sshot.png
- Stefan
- Posts: 2051
- Joined: November 5th, 2002, 2:46 am
Re: Flash Ad blocking
Ted Mielczarek wrote: The main problem with my hack implementation right now is that it hides everything after they've been loaded, which defeats the purpose of disabling flash to save bandwidth. I'm not sure what would be required to make that happen, but I'm looking into it.
Donno if it helps, but the specified type="" is there so browsers can use the mimetype to determine if it's content they understand and can show. If not they are not supposed to download it.
If this is correct making the browser think it's something it can't display should thus trick it into not downloading it in the first place.
Of cource there are problems like what happens when type is missing?
-
- Posts: 1269
- Joined: November 5th, 2002, 7:32 am
- Location: PA
- Contact:
stefan:
The real problem is that javascript and CSS styles don't take effect until after the whole page is loaded, plugins, images and all. To achieve the desired functionality, code would have to be inserted somewhere down near the network layer. Scary stuff.
I just noticed that I linked the wrong bug up above. The second bug should be a link to: http://bugzilla.mozilla.org/show_bug.cgi?id=169330
The real problem is that javascript and CSS styles don't take effect until after the whole page is loaded, plugins, images and all. To achieve the desired functionality, code would have to be inserted somewhere down near the network layer. Scary stuff.
I just noticed that I linked the wrong bug up above. The second bug should be a link to: http://bugzilla.mozilla.org/show_bug.cgi?id=169330
- chrisMage
- Posts: 23
- Joined: November 5th, 2002, 8:14 am
- Location: Alabama
- Contact:
How about this?
How about this approach:
Allow the user to specify wildcard URLs for image-blocking. For example, slashdot hosts some of its banner ads on images.slashdot.org. If I blocked images.slashdot.org, all of slashdot's images would be blocked. But, If I could specifically block http://images.slashdot.org/banner/* , only the ads would be blocked. Bada-bing, bada-boom.
Allow the user to specify wildcard URLs for image-blocking. For example, slashdot hosts some of its banner ads on images.slashdot.org. If I blocked images.slashdot.org, all of slashdot's images would be blocked. But, If I could specifically block http://images.slashdot.org/banner/* , only the ads would be blocked. Bada-bing, bada-boom.
-
- Posts: 1269
- Joined: November 5th, 2002, 7:32 am
- Location: PA
- Contact:
Re: How about this?
chrisMage wrote:How about this approach:
Allow the user to specify wildcard URLs for image-blocking. For example, slashdot hosts some of its banner ads on images.slashdot.org. If I blocked images.slashdot.org, all of slashdot's images would be blocked. But, If I could specifically block http://images.slashdot.org/banner/* , only the ads would be blocked. Bada-bing, bada-boom.
That's taken care of with this bug: http://bugzilla.mozilla.org/show_bug.cgi?id=78104 (there's even a patch for it attached). Unfortunately this still doesn't do what I want, since it won't a) preemptively handle new sites I visit, or b) Give me the option of viewing the plugin, which I may want to do. Maybe I'm just really picky. :)
- Stefan
- Posts: 2051
- Joined: November 5th, 2002, 2:46 am
Re: How about this?
Ted Mielczarek wrote:Maybe I'm just really picky.
Picky is good.
Nobody wants a semibroken feature anyway
-
- Posts: 1269
- Joined: November 5th, 2002, 7:32 am
- Location: PA
- Contact:
Stefan wrote:Ted Mielczarek wrote:To achieve the desired functionality, code would have to be inserted somewhere down near the network layer. Scary stuff.
Are you a man or a mouse ;)
Haha, have you *looked* at the C++ code? I've been programming in C++ for about 6 years, and the Mozilla code is still hard to read. I did find some interesting leads last time I looked around, so I might go back and actually try my luck at implementing this correctly once I get my new computer setup.
It looks like this project: http://sardine.mozdev.org/ has the right idea, but still implemented at the wrong level, like my stuff. They do realize this, but the author isn't supporting the project anymore. I also can't find the source code for it via web CVS, haven't tried normal CVS yet. It supports arbitrary rewriting of page content. Might be a bit much to implement correctly, but it's a nice lofty goal.
- Stefan
- Posts: 2051
- Joined: November 5th, 2002, 2:46 am
Ted Mielczarek wrote:Haha, have you *looked* at the C++ code? I've been programming in C++ for about 6 years, and the Mozilla code is still hard to read.
Hehe nope, that sounds like it's way over my head
Anyway, from your description it certainly sounds like a good implementation would really have to dig that deep.
Mayby you should try to ask around in the chatchannel and see if you could pick up a lead or two to how to procede if you decide to give it a shot
Who knows, mayby the original networklayer coders might give you a hint or two.
-
- Posts: 187
- Joined: November 28th, 2002, 7:53 pm
Re: How about this?
chrisMage wrote:How about this approach:
Allow the user to specify wildcard URLs for image-blocking. For example, slashdot hosts some of its banner ads on images.slashdot.org. If I blocked images.slashdot.org, all of slashdot's images would be blocked. But, If I could specifically block http://images.slashdot.org/banner/* , only the ads would be blocked. Bada-bing, bada-boom.
I suggest checking out www.adshield.org. Its for IE, but it gives (to me) a great idea of how the idea should be implemented.
At mozdev a project that looks promising called AdBlock was just started. One thing I kinda like from AdBlock is it still downloads the image, but doesnt show it. I know your thinking, why would you want to still download it? Because that way they think we are still viewing the ads, but we are not. If they see a million hits to their webpage and none to the ad server they are gonna realize people are using ad-blocking, and switch to a better way of serving ads (I can already think of a few).
Edit: Forgot to mention that AdShield works on flash as well.