Improvement requests :  K-Meleon Web Browser Forum
Use this forum to talk about a feature you're missing. 
Adblock?
Posted by: g.ee
Date: January 25, 2005 06:52AM

I like the look of this browser, but I'm not accustomed to seeing all of the advertisements that adblock has let me forget about. Are there any plans to develop an adblock-like tool to prevent loading flash and image files from websites? I found the privacy section for denying images from a site, but it doesn't seem to be specific enough-- I might want to block the images at http://www.somewebsite.com/ads/* but see others from the same host.

Options: ReplyQuote
Re: Adblock?
Posted by: rmn
Date: January 27, 2005 11:03AM

You can do that from userContent.css (Tools>Advanced Preferences>UserContent):
Add
img[src*="somewebsite.com/ads/"] {display:none !important}
or simply
img[src*="/ads/"] {display:none !important}
then restart K-Meleon.

Options: ReplyQuote
Re: Adblock?
Posted by: Mueen
Date: January 31, 2005 06:47AM

Does it support blocking via regular expressions?

Options: ReplyQuote
Re: Adblock?
Posted by: rmn
Date: January 31, 2005 10:24AM

Nope, there's nothing in K-Meleon that really compares to Adblock. And by the way, that userContent.css trick seems to still cause the image to be downloaded (only not showed).

Options: ReplyQuote
Re: Adblock?
Posted by: atordo
Date: January 31, 2005 09:02PM

You could use an external application like privoxy which allows the use of regexps.

Options: ReplyQuote
Re: Adblock?
Posted by: Dude
Date: January 31, 2005 10:43PM

If im not mistaken those CSS dont block the ads from downloading in the first place while with ad block the script/ads etc never are downloaded.

Options: ReplyQuote
Re: Adblock?
Posted by: g.ee
Date: February 03, 2005 12:20AM

I'm frankly more concerned about flash files (.swf) than images-- are there any programs that can prevent those from loading? I use a firewall (agnitum outpost) that lets me block images, but not (afaik) other kinds of ads.

Options: ReplyQuote
Re: Adblock?
Posted by: jsnj
Date: February 03, 2005 09:10AM
Options: ReplyQuote
Re: Adblock?
Posted by: arkanbh
Date: February 13, 2005 05:13PM

please,

create an tool for add block ads in kmeleon...import of adsblock settings...

Thanks

Options: ReplyQuote
Re: Adblock?
Posted by: mlog
Date: February 16, 2005 04:24PM



Options: ReplyQuote
Re: Adblock?
Posted by: maty
Date: February 21, 2005 05:19PM
Options: ReplyQuote
Re: Adblock?
Posted by: Drahken
Date: February 21, 2005 06:06PM

g.ee, there's an easy way to block flash in k-meleon, just go privacy->block flash. That will prevent flash items from loading. (You'll have to turn it back on if you go to a site that requires flash to work, but it's an easy thing to toggle on/off.)

Options: ReplyQuote
Re: Adblock?
Posted by: ndebord
Date: February 21, 2005 06:22PM

g.e.e.,

In addition to what they've mentioned here, to stop flash ads from loading on the fly, I use the privacy toolbar <<KillFlash>> button to individually kill of annoying flash ads as they bother me when I'm surfing.

N

Options: ReplyQuote
Re: Adblock?
Posted by: Drahken
Date: February 27, 2005 06:23PM

You can achieve results similar to those of adblock by using a PAC file. The PAC file has to be edited manually to add or remove filters, but it can block just a directory or even just a single image in addition to blocking entire sites, and (unlike the usercontent method) it prevents the images from being downloaded. Here's how to get PAC files to work in KM:


==FOR THOSE OF YOU NOT USING THE HAO CCF 0.019a2 (or later) VERSION==
Download this file:
http://allspark.net/cypherswipe/nsProxyAutoConfig.js
Close k-meleon. Place the file in the components folder in your k-meleon folder (something like c:/program files/k-meleon/components/), click "yes" when it asks if you want to overwrite the existing file. Delete the compreg.dat file located in the same folder. (It'll be rebuilt the next time to load k-meleon.)

Fire up k-meleon and click
edit->prefs->proxy->automatic proxy config URL
and put file://C:/adfilter2.pac (or where ever you saved the .pac file to) as the URL.To test it, go to http://googlesyndication.com, you should have just a blank page. If you get a google site, close k-meleon and reopen it.
==============================

Once you have done that, or if you are using the above mentioned version:

Download this file:
http://allspark.net/cypherswipe/adfilter2.pac.txt
Remove the .txt extension.

To add or remove something from the filter list, just open the pac file in notepad or any other text editor. You will see a bunch of lines like this:
shExpMatch(url, "*clickthru*") ||
To remove something, simply find the line that mentions it and delete it. To add something, just add a new line and replace *clickthru* with whatever you want to block. The *'s are wildcards.
For example,
shExpMatch(url, "*stupid-image.jpg") ||
would block the file called "stupid-image.jpg". You can block single images, whole directories, or even whole sites using this method.

If you need to (or just desire to) connect through a proxy, go to the end of the file and look for the line
return "DIRECT";
Replace "DIRECT" with "PROXY [address]:[port]". For example: "PROXY 216.532.25.23:82"

Options: ReplyQuote
Re: Adblock?
Posted by: ogurec
Date: March 03, 2005 09:54AM
Options: ReplyQuote
Re: Adblock?
Posted by: jh
Date: April 15, 2005 08:35AM

why not just alter adblock itself? source is available, so just make it work with k-meleon. it's the same plug-in api.

Options: ReplyQuote


K-Meleon forum is powered by Phorum.