Yeah, ignore the URL in the last frame of that nifty animated
graphic.
Ads are a
fact of life!
As much as I'd love TV, Radio, the web, print media, etc. to be free
of ads, the fact is that is often the only way to make any money to pay
for all the work that goes into the TV programs, music, articles, and
valuable information produced today. In fact, I'm trying a piddly little
attempt to make a little money off this site with the box shown here:
In another article, I instrumented the more popular pages of this
site with a single ad box like shown above just to see - how much can a
small website actually make off ads? Is it enough to even bother? The
answer is in an article you can find here.
But lately, the ads have gotten way too invasive. In the old days, it
was pop-ups all over your screen. Once pop-up blockers became
commonplace and even integrated into the browsers, now they've come up
with these roll-over or mouse-over ads - annoying things that look for
any interesting words on the site and make any mouse movement over that
word pop an ad up for something related to the word.
Be reasonable! Do you really think that if you make the ad more
annoying you'll convince me to click on it?
So anyway, here is how to eliminate them!
Find the
code that does the roll-over pop-up ads
This isn't hard, but it does require a very small bit of familiarity
of what HTML code and Javascript code both look like and a willingness
to experiment on your part. The reason is that
HTML code can't do the pop-ups -- though I believe some creative folks
will find a way to make DHTML (Dynamic HTML) do the pop ups, right now
that is all done with Javascript. So the first thing is to look at the
code and see if you can identify the javacsript.
To see the code, from Internet Explorer hit the View menu and then
select View Source.
A great big text file will open up with all the code that represents
the page you are now looking at.
You are looking around for something that looks like this:
<script language="javascript"
Between that bit of text and something that looks like this:
</script>
you are looking for references to other websites where they might be
digging code from.
Not all
Javascript is undesirable -- just the mouse-overs
Close to the top, you'll see a bit of code that looks like this (or
at least it did when I grabbed the captured file):
<script type="text/javascript" src="http://w.sharethis.com/widget/?tabs=web%2Cemail&charset=utf-8&services=%2Cfacebook%2Cmyspace%2Cdelicious%2Cdigg%2Cgoogle_bmarks%2Cyahoo_myweb%
Now it might read like stereo instructions, but if you read the
English words and skip the rest, it sure looks like it refers to a site
called http://w.sharethis.com and
it talks about facebook, myspace, delicious, digg, google_bmarks,
yahoo_myweb, ... so this is likely a bit of code that allows you to do
something with those websites easily.
So this is not the code you are looking for...
You'll see all kinds of stuff, like this bit of code that goes and
gets an ad for you to read. If they are not animated and not annoying, I
let them live -- otherwise, I'll kill them just as dead as the mouse-overs:
<SCRIPT LANGUAGE='JavaScript1.1' SRC='http://ad.doubleclick.net/adj/"
+ tag_vars+ "dcopt=ist;tile=1;loc=top;sz=728x90;ord=" + myNum798 +
"?'></" + "script>";
document.write(adstring)
ad.doubleclick.net serves ads up to various websites.
Found!
Those nasty pop-ups!
Close to the bottom of the page, you'll find this little bit of code.
Click on the smaller image to see it full-size. The first bit underlined
in blue is a pointer to
http://js.revsci.net, followed by a comment in red talking about
this being the "Vibrant Media IntelliTXT script section.
BINGO!
The next link on the line below in red is another script tag pointing
to
http://popphoto.us.intellitxt.com, and three lines below that is a
pointer to
http://edge.quantserve.com
Collect up all those links. You've done the hard part -- the rest is
easy.
Nuking it
forever
Instead of having your browser go out and get all the code and stuff
from those sites, we're going to have your system go somewhere it will
never get any code from unless you want it to -- we're going to send it
to "localhost", or the IP address 127.0.0.1, which is an IP address that
represents your own computer no matter what its public IP address is.
To do that for just your system, you'll edit your hosts file. The
path to that file on Windows XP is usually here:
c:\windows\system32\drivers\etc\hosts
But if your windows was installed in a different directory -- say
c:\winnt, then you'd use the path:
c:\winnt\system32\drivers\etc\hosts
You'll want to edit that file in notepad, then point those addresses
at 127.0.0.1 instead of letting them go out on the web and get their
annoying pop-up mouse roll over code.
The first line that reads:
127.0.0.1 localhost
Leave that line alone. Add the next 2, 3, 4, or however many you need
to add for all the URLs that make the mouse overs work. How do you know?
Try a couple, save the file, exit and re-enter your browser, and go back
to the same site.
If the pop up mouse overs are gone, you have successfully killed
them. If they aren't gone, try a few more. You can see I didn't actually
need to kill edge.quantserve.com -- killing things that aren't part of
the problem might make the site not work, so be careful and only kill
what you need to!
You can find a very nice hosts file that kills lots of malware and
spyware dead in its tracks at this location:
http://www.mvps.org/winhelp2002/
Minor notes for Windows 7 and Windows Vista
users:
You will only be able to write to the hosts file if you are editing
the file as an administrator. One easy way to get there is to hit the
start button, and in the search box type cmd.exe. Wait for search to
find and show you in Programs the "Command Prompt", then move the mouse
up to it, right-click, and select "Run As Administrator". From
that prompt, you can type:
cd
c:\windows\system32\drivers\etc
notepad hosts
and then you'll be editing the hosts file as an administrator.
Update 10/2012:
If you found this helpful or not, please send me a brief email! I'm also playing around with making a product that could do a lot of this automatically, maybe selling it as a download for $5-10.
If this is something you might be interested in, please let me know in an email - one
line will more than do. If I see enough interest, I'll write it!
I'm also experimenting with the whole social media thing. If you liked
this and have a facebook account, please show a little love and like the
article:
I can be reached at:
das (at-sign) dascomputerconsultants (dot) com
Enjoy!
David Soussan
(C) 2009, 2012, 2014 DAS Computer Consultants, LTD. All Rights Reserved.
Everything below this line is to help search engines find, index, and
thus help users find this content.
Pop-ups
Mouse-overs
Kill mouse over |