Helping people with computers... one answer at a time.

Ask Leo! is free, but advertising supported. If those ads get in your way, here's a way to turn them off.

You recently added a new type of advertising on your site which looks like a slightly different form of hyperlink. Now, normally this wouldn't be a problem, I am always in favor of keeping content free though recouping hosting costs with advertising , but this new form not only severely impacts Opera's keyboard navigation, but somehow manages to reformat the whole page's text if Opera's zoom function is in use and one of the links is highlighted (which is unavoidable with keyboard navigation), making it unreadable.

Can I turn it off. Please?

As you point out, Ask Leo! is a completely free service, and primarily advertiser supported.

The neat thing about the advertising programs that Ask Leo! uses, is that they are "contextual" - meaning they relate to the content being presented. Even though I have no control over which ads are displayed, quite often those ads are part of the very solution that readers are looking for.

But I definitely don't want ads to get in the way of your ability to even view Ask Leo! pages, so at the risk of decreasing the advertising income a little, I'll show you how you can turn it off.

I know you're running Opera, but by far the easiest way I can think of is the NoScript extension to FireFox. Most advertising of this form is presented through the use of Javascript code blocks. By instructing NoScript to disallow scripts from and from, these in-line ads will no longer be displayed. (Opera may have this functionality, I'm not sure.)

OK, so there's one simpler way and that's to disallow all Javascript everywhere. The problem here is that so many sites require Javascript for their functionality turning it off everywhere just isn't practical, in my opinion.

If you can't disable scripting on a site-by-site basis, then the next best thing is to modify your hosts file to prevent access to the advertiser's site.

I've talked about modifying the hosts as a way to fake DNS when you're testing a new website, but it's also a common technique for blocking unwanted advertising.

Using a text editor such as notepad, add these lines:

to the text file c:\windows\system32\drivers\etc\hosts - or the same file elsewhere if your Windows installation is in a directory other than C:\windows. In any case, the file should already exist.

What this does is tell your computer that "" and "" are located at, which is a shorthand for your own machine. Of course it's not really there, so the access to get the advertising Javascript fails, and fails quickly. The result? No ads.

Depending on how aggressively your browser or your system caches files, you *may* need to exit and restart your browser, or even reboot to flush appropriate caches before the ads disappear.

Hope that helps. Even if you can't see my ads, I'm glad you find Ask Leo! valuable enough to want to take these steps.

Article C1823 - January 3, 2003 « »

Share this article with your friends:

Share this article on Facebook Tweet this article Email a link to this article
Leo Leo A. Notenboom has been playing with computers since he was required to take a programming class in 1976. An 18 year career as a programmer at Microsoft soon followed. After "retiring" in 2001, Leo started Ask Leo! in 2003 as a place for answers to common computer and technical questions. More about Leo.

Not what you needed?

Comments on this entry are closed.

If you have a question, start by using the search box up at the top of the page - there's a very good chance that your question has already been answered on Ask Leo!.

If you don't find your answer, head out to to ask your question.