So you have a home page on GeoCities. The price is right (free), but there is a problem: whenever somebody opens your page, an annoying ad appears in the right side of the page.
Those of your home page visitors that are running Foxy or other content filtering software won't see those ads, but what about the rest of them? Don't you fret. It's easy to neutralize the JavaScript code added by GeoCities right there, on the server side.
Whatever the added code does, it has to call document.write() or document.writeln() to modify your page's content, or window.open() to show their popups. The idea is to neutralize those functions. The GeoCities code will still call them, but they will do nothing.
If your page is static (doesn't use those functions), just add the fragment below somewhere before the opening <body> tag of your pages:
If your pages do use functions like document.write(), save them under new names, and call them instead of the neutered original functions:
From time to time the GeoCities people will come up with new schemes. Just spend a few minutes studying the source of the modified pages, and you will figure out how to undo their changes.