The Omni Group
These forums are now read-only. Please visit our new forums to participate in discussion. A new account will be required to post in the new forums. For more info on the switch, see this post. Thank you!

Go Back   The Omni Group Forums > OmniWeb > OmniWeb Feature Requests
FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
Ad blocking no questions asked Thread Tools Search this Thread Display Modes
I used the 5.5 betas for about the length of a trial period and ended up coming back to safari. I miss site preferences, its speed advatage, the lightweight look, tab thumbnails (Stand does nothing but annoy me...) everything. except ad blocking. I know everyone is like "it works fine, you just need..." and on the list are a perfect blocklist, because if one thing isn't a regex OW can understand the whole thing goes down the tubes. Also there is custom CSS and other things I have heard. Why can't this just be simpler, like everything else in this app seems to be. Why can't I just put the filterset.g text file in line by line (As I spent time doing) and expect it to work? I keep my ow5 prefs file, and I will be trying out new OW releases until omniweb's ad blocking, like everything else on my mac Just WorksTM. Once it does, I will be delighted to switch back.
 
I just check Matching known ad sizes, From third-party sites and From blocked URLs. Then I adjust the site prefs or hit command+shift+i as needed. Sometimes I right-click and hit Filter image.

I might mess with the blacklist, manually, once a month.
 
A little late, I know—just came back from a vacation. :-)

How is that filterset.g file formatted? With the usual glob patterns, i.e. "*" stands for "zero or more 'anychars'", "?" stands for "exactly one 'anychar'"?

If the file only contains URLs, line by line, you just have to replace "*" by ".*", "?" by ".", and "." by "\.".

As I don't have to work for another week, I would write a simple perl script that does the changes if anyone is interested. You could then just copy&paste the lines of the resulting file.
 
Quote:
Originally Posted by zottel
A little late, I know—just came back from a vacation. :-)

How is that filterset.g file formatted? With the usual glob patterns, i.e. "*" stands for "zero or more 'anychars'", "?" stands for "exactly one 'anychar'"?

If the file only contains URLs, line by line, you just have to replace "*" by ".*", "?" by ".", and "." by "\.".

As I don't have to work for another week, I would write a simple perl script that does the changes if anyone is interested. You could then just copy&paste the lines of the resulting file.
I would be very interested in that script!! That's the one thing about FF I love, Fiterset.G

Attach it here if possible and I will provide feedback.

Thanks!
 
Where can I get a filterset.g file to see how it is formatted?
 
Hm, the host seems to be down atm. I'll see into this soon when I can get sth from there. :-)
 
Rick's Easyfilter is the cream of the crop when it comes to Adblock filter subscriptions. You can find it here:

http://easylist.adblockplus.org/adblock_rick752.txt
 
Hello,
Could someone please tell me how to import
the adblocking filters into omniweb...
Alas...I have tried and failed.
Thanks in advance for any help.
Peace
Stuart
 
I still couldn't connect to the pierceive host, so I used the link jcraig posted. So here is a small perl script (link at the bottom of this post) that will translate this file into usable regular expressions with some small caveats:

– "$" seems to have a special meaning in the patterns used for Adblock Plus. I don't know what meaning this is, though, so I left these lines out. If you see a blank line in the output of glob2re.pl, it means that the script encountered a line containing a "$" and thus coudn't provide a translation.

– "?" isn't used with the meaning it normally has in glob patterns, but as a literal "?". glob2re.pl will match this behaviour instead of doing the translation "normal" glob patterns would need. So if you want to translate anything else than files for Adblock Plus, some lines might not work.

– The lines below "! WHITELIST---" are for the whitelist, obviously. Don't enter this line and the "!" at the end of the whitelist as ad blocking lines in OW. Just leave them out. Enter the lines after "! WHITELIST---" in the lower box of the ad blocking settings in OW.

– Don't enter the lines at the beginning of the file, the one that contains "[Adblock Plus" and the ones starting with a "!" directly below.

To use the script, download the file at the bottom of this post and put it into some directory where you will find it again. ;-) Open the Terminal and type

cd <yourdirectory>

where <yourdirectory> is the directory you put glob2re.pl in. If you don't know where it actually is, you can open the parent directory of <yourdirectory> in the finder, type "cd " in the terminal (note the space after cd) and then drag&drop <yourdirectory> from the finder to the terminal and hit enter.

Now you have to make glob2re.pl executable. To do this, type:

chmod 0755 glob2re.pl

Now it's ready to use. Whenever you want to use it, first cd to <yourdirectory> as shown above.

glob2re.pl uses a parameter you give to it as a file name to read the glob patterns from. If you don't give it a parameter, it will read from stdin. This means it waits for you to type in or paste glob patterns and will then translate those to regular expressions. It will do so until you press Ctrl-d. If you want to have your output in a file, just add "> yourfile.txt" at the end of the command line.

Examples:

To enter or paste glob patterns in the terminal and directly see the results, enter:

./glob2re.pl

It will then wait for input until you press Ctrl-d.

The same, but don't see the results, instead collect them in the file "filter.txt":

./glob2re.pl > filter.txt

Read the file adfilter.txt (which resides in <yourdirectory>) and see the output in the terminal:

./glob2re.pl adfilter.txt

Read the the file thisfilter.txt on your desktop and put the results into the file filter.txt:

./glob2re.pl ~/Desktop/thisfilter.txt > filter.txt

The lines glob2re.pl spits out can directly be used as lines for ad blocking in OmniWeb.

Note: If you download and translate a filter file that is formatted for windows, you might see "^M" at the end of each line of the output of glob2re.pl, depending on what viewer you use to view the results. Don't try to enter those "^M"s in OmniWeb, just leave them out.

Here is the link to the script. Right- or Ctrl-click on the link and choose "Save link as ...".

http://mac.zottel.net/glob2re.pl

(Note: This link resides on my home mac via a dialup line. I'm normally online 24h/day, but if you happen to try it just at the moment a 24h-reconnect occurs, it might not work. Just try again a few minutes later.)

Note: This is just a small hack. No guarantee whatsoever, use at your own risk. No license, just redistribute and/or reuse as much as you want. ;-)

Last edited by zottel; 2006-11-12 at 08:49 AM..
 
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Mac App Store Frequently Asked Questions jbrown OmniFocus 1 for Mac 28 2012-07-29 06:25 PM
OmniFocus for iPad Frequently Asked Questions Brian OmniFocus for iPad 0 2010-04-02 02:21 PM
Frequently Asked Questions Re: OmniFocus Synchronization Brian OmniFocus Syncing 0 2008-07-14 02:49 PM
Frequently Asked Questions about OmniFocus for iPhone Brian OmniFocus for iPhone 0 2008-07-09 10:54 AM
What sort of questions can be asked here? Patrick923 OmniPlan General 1 2008-02-04 10:46 AM


All times are GMT -8. The time now is 04:47 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.