Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Mitthrawnuruodo

Moderator emeritus
Original poster
Mar 10, 2004
14,424
1,065
Bergen, Norway
Disclaimer: This is not a thread about how to get rid of ads in general! So please don't wasteland, it even if it mentions some adblocking techniques. :eek:

Background: I've been using Safari 2.0 since upgrading to Tiger. And I'm very happy with it. It seems to be working with my internet bank (which 1.3 didn't do), the RSS feature is awesome, they've finally added a "send link"-function and after I installed Taboo Safari now asks me if I really want to quit when I have more than one tab open. :)

But I really want to get rid of those annoying flash ads some sites have in abundance. :mad:

I know about Pithelmet, but when I tried the newest version yesterday, it froze my Safari twice in the 15 minutes I tried it, not to mention that I'm not that keen on paying for 3rd party Safari hacks. It didn't look too easy to configure, either, and I'm a computer engineer. :rolleyes:

Over at Pimp My Safari I also came across a method of making a userContents.css file, but I found that this method took out all ads on all sites, except flash ads, and specially those started from scripts. The exact opposite of what I'm after. :rolleyes:

The real downside with both those methods is, as mentioned before, that I'm not looking for an ad blocker, per se, I don't mind text ads or even animated gifs, but I hate flash ads, and especially flash ads with sound or those new ones spawning pop-ups/-unders. They are a real pain in more than one body part. :mad: All of my filters in Firefox' Adblock follows the pattern: "*some.adprovider.domain/*.swf*", and I even have a generic "*.ad*.swf*", which is very effective. :cool:

I've also tried editing the /etc/hosts file, and although that got rid of some, many others, specially those triggered from scripts, got through. Even if they originated from domains I had blocked. :confused:

Un-checking "Enabling plug-ins" under Security in Safari preferences helps, but is not really an option as it kills of all objects, even text or movie ones.

So the question is: Does anybody know about a Flash blocker (or very configurable ad blocker á la the Adblock extension in Firefox) for Safari 2.0? This feature is now the only thing I miss enough to keep me from switching back to Safari permanently (of course I miss the Search-bar in Firefox, too, but not enough).
 

mkrishnan

Moderator emeritus
Jan 9, 2004
29,776
15
Grand Rapids, MI, USA
Mitthrawnuruodo said:
(of course I miss the Search-bar in Firefox, too, but not enough).

The main question is of interest to me, too, and I don't have an answer (well, I *think* I know how to block Flash using PithHelmet, but only if I can get the URL of the flash, which there doesn't seem to be any easy way to do in Safari).

But... have you tried AcidSearch for the search bar? In some ways I think it's actually better than FF's. For instance, it's much easier to set up a new search option for a site that doesn't have an FF searchplugin in AcidSearch than it is to write a plugin for FF. I had some pretty cool stuff set up in there quite easily, like a google search of MR forums, and a similar one for Fred Miranda, package trackers for USPS/UPS/Fed-Ex/AirEx, etc.... (I'm sure you can do package tracking for your own national postal service too! ;))
 

Mitthrawnuruodo

Moderator emeritus
Original poster
Mar 10, 2004
14,424
1,065
Bergen, Norway
Thanks, AcidSearch looks great. Does it work with Tiger? There was some controversy with Safari 2 and a few of the add-ons, wasn't it?

And, I wasn't really referring to that search bar, even though I miss that, too. I was thinking of the "Find..." function (cmd-F) for searching the content on the current webpage. ;)

But I'll try AcidSearch if someone confirms it works with Safari 2.0. :)
 

mkrishnan

Moderator emeritus
Jan 9, 2004
29,776
15
Grand Rapids, MI, USA
Mitthrawnuruodo said:
Thanks, AcidSearch looks great. Does it work with Tiger? There was some controversy with Safari 2 and a few of the add-ons, wasn't it?

Yes, 0.41 works for me in Tiger. Actually, AcidSearch does *both* of those things -- it has the find as you type bar too. But that doesn't seem to work quite perfectly for me, in Tiger (the main aspect of AcidSearch works fine). In Panther, the find-as-you-type bar in Safari is very much like the one you get in FF.
 

wrldwzrd89

macrumors G5
Jun 6, 2003
12,110
77
Solon, OH
I use Safari's Activity window for finding the URLs for any type of content, including Flash ads. It also comes in handy for finding out why a particular page element failed to load.
 

Mitthrawnuruodo

Moderator emeritus
Original poster
Mar 10, 2004
14,424
1,065
Bergen, Norway
wrldwzrd89 said:
I use Safari's Activity window for finding the URLs for any type of content, including Flash ads. It also comes in handy for finding out why a particular page element failed to load.
Yes, that's ok, but how do you get rid of those containing a .swf file from a typical ad site?

mkrishnan: AcidSearch worked like a charm, I was even able to make it search my local library (which I never managed to get Firefox to do) :)

Here's what I got now, after deleting most of the default ones, and starting to add "my own":
 

Attachments

  • Picture 1.png
    Picture 1.png
    21.9 KB · Views: 2,597

wrldwzrd89

macrumors G5
Jun 6, 2003
12,110
77
Solon, OH
Mitthrawnuruodo said:
Yes, that's ok, but how do you get rid of those containing a .swf file from a typical ad site?

mkrishnan: AcidSearch worked like a charm, I was even able to make it search my local library (which I never managed to get Firefox to do) :)

Here's what I got now, after deleting most of the default ones, and starting to add "my own":
I just edit my /etc/hosts file. I've even made a script to update the real file when I add new stuff to a data file.

I was wondering if it's possible to add /etc/hosts filters by directory in addition to by domain.

That is, could I do this:

---/etc/hosts extraction---

127.0.0.1 foo.site.com
127.0.0.1 bar.site2.org/ads

---end /etc/hosts extraction---

...and have bar.site2.org/files, as well as other directories on bar.site2.org, not be blocked?
 

Mitthrawnuruodo

Moderator emeritus
Original poster
Mar 10, 2004
14,424
1,065
Bergen, Norway
wrldwzrd89 said:
I just edit my /etc/hosts file. I've even made a script to update the real file when I add new stuff to a data file.
As I said above, I tried the /etc/hosts approach without a very good result. On the four Norwegian news sites I frequent most often I only managed to filter out a few flash ads. I even saw in the Activity Monitor that Safari happily added contents from flash.vg.no even if I had blocked that. Tried both 127.0.0.1 flash.vg.no and 0.0.0.0 flash.vg.no, whit very limited result. Dagbladet was even worse as they have both ads and graphics in gfx.dagbladet.no. And even notorious sites like ---.---.adform.net and ---.tradedoubler.com managed to slip lots of flash stuff past the host file, which Firefox' Adblock easily stops with my filters: "*.tradedoubler.com/*.swf*" and "*.adform.net/*swf*".

And, again, I don't want to block all ads. So, even if I got the /etc/hosts file tuned, that would then block all ads, and I don't really want that. Most ads are good. Flash ads are bad. :)
 

wrldwzrd89

macrumors G5
Jun 6, 2003
12,110
77
Solon, OH
Mitthrawnuruodo said:
As I said above, I tried the /etc/hosts approach without a very good result. On the four Norwegian news sites I frequent most often I only managed to filter out a few flash ads. I even saw in the Activity Monitor that Safari happily added contents from flash.vg.no even if I had blocked that. Tried both 127.0.0.1 flash.vg.no and 0.0.0.0 flash.vg.no, whit very limited result. Dagbladet was even worse as they have both ads and graphics in gfx.dagbladet.no. And even notorious sites like ---.---.adform.net and ---.tradedoubler.com managed to slip lots of flash stuff past the host file, which Firefox' Adblock easily stops with my filters: "*.tradedoubler.com/*.swf*" and "*.adform.net/*swf*".

And, again, I don't want to block all ads. So, even if I got the /etc/hosts file tuned, that would then block all ads, and I don't really want that. Most ads are good. Flash ads are bad. :)
One thing about updating the /etc/hosts file: in order for any changes to take effect, you must either:

1. Send a HUP to lookupd (killall -HUP lookupd) from the Terminal
2. Restart
 

Mitthrawnuruodo

Moderator emeritus
Original poster
Mar 10, 2004
14,424
1,065
Bergen, Norway
wrldwzrd89 said:
One thing about updating the /etc/hosts file: in order for any changes to take effect, you must either:

1. Send a HUP to lookupd (killall -HUP lookupd) from the Terminal
2. Restart
I know, actually I tried lookupd -flushcache, logging out/in and restarting, without any improvement... ;)

I spend most of the day yesterday and a couple of hours today trying to get all the above mentioned techniques to work. Because, and I cannot stress this enough, the un-ability to filter out exaggerated flash use is a major deficiency in Safari, and may very well, unwillingly, send me back to Firefox... :(
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.