AAO25.com

Community => Games & Programming => Topic started by: Spanky on Thursday, March 18, 2010, 01:08:41 AM

Title: [How To] Excellent Ad-Blocking
Post by: Spanky on Thursday, March 18, 2010, 01:08:41 AM
This is just a temporary post until I get my stuff together... Basically, you copy the contents of the hosts file into your Windows hosts file. Then, whenever you visit a website, the ads (or any site blocked by the host file) will redirect to 127.0.0.1 but unless you want a "page not found" error, we need to run a web server there. We do this with PixelServ which is a Perl program which requires ActivePerl, then we run PixelServ as a scheduled task when the user logs on and presto, clean and advertisement free webpages. But... I'm too tired right now and I needs sleep for tomorrow. Those that want to try this out, go for it but I'll have more detailed instructions later.

You Need:

Instructions:
Code: [Select]
$sock = new IO::Socket::INET (  LocalHost => '0.0.0.0',to
Code: [Select]
$sock = new IO::Socket::INET (  LocalHost => '127.0.0.1',
Code: [Select]
cd c:\perl
perl -w -t pixelserv.pl
Now, if all went well. You should be able to double click on the batch file (run it) and ads will disappear on websites.

If you want to automate this, you can drop the batch file into your startup folder (boring) or you can use Task Scheduler to run it automatically.
Here's some screenshots that I shot of my setup in Task Scheduler:
http://dl.dropbox.com/u/464376/headshot/hosts/Capture1.PNG
http://dl.dropbox.com/u/464376/headshot/hosts/Capture2.PNG
http://dl.dropbox.com/u/464376/headshot/hosts/Capture3.PNG
http://dl.dropbox.com/u/464376/headshot/hosts/Capture4.PNG
http://dl.dropbox.com/u/464376/headshot/hosts/Capture5.PNG
http://dl.dropbox.com/u/464376/headshot/hosts/Capture6.PNG
Title: Re: [How To] Excellent Ad-Blocking
Post by: Spanky on Thursday, March 25, 2010, 02:27:04 AM
Updated with a little more complete instructions.