NodeReaper has asked for the wisdom of the Perl Monks concerning the following question:

This node falls below the community's threshold of quality. You may see it by logging in.

Replies are listed 'Best First'.
Re: Pop-Up Ads
by Juerd (Abbot) on Jan 22, 2002 at 14:11 UTC
    Check out YAFP (Yet Another Filtering Proxy). It's written in Perl and based on an example by merlyn.

    I found this using "filtering proxy perl" as keywords on Freshmeat.


    This does not answer your question, because you want a hosting-side solution where post-parsing (probably) inserts the code. However, it can help you get rid of pop-ups client-side.

    You might not realise it, but your question is not Perl related (btw, it's Perl, not PERL).

    2;0 juerd@ouranos:~$ perl -e'undef christmas' Segmentation fault 2;139 juerd@ouranos:~$

Re: Pop-Up Ads
by George_Sherston (Vicar) on Jan 22, 2002 at 18:18 UTC
    I'm not an expert in this field but AFAIK there are two reasons why visitors to your site wd get pop-ups - (A) because you put javascript in your own pages to create them and (B) because your web host sends them. Presumably we can rule out (A). If you are linking to pages you don't control and want to destroy pop-ups from them, you *could* replace the link with a link to a script that would use LWP::Simple or some such to get the text of the chosen page, then a regex (or perhaps HTML::Tagfilter) to delete any offending javascript, and then send the surviving text to the browser. But that would be a bit of a schlep, and you'd also have to take care that any links in the page were (or became) absolute links. And that probably isn't your problem anyway. Presumably your problem is (B), in which case there is a

    SIMPLE SOLUTION

    Namely, get a different internet service provider. There are lots of people who will give you free webspace without junking it up with pop-ups and other nonsense. In fact there is probably an inverse correlation between junk and quality of package offered. Two in the UK that do this well are http://www.uklinux.net and http://www.dsvr.co.uk.

    § George Sherston
Re: Pop-Up Ads
by fuzzysteve (Beadle) on Jan 22, 2002 at 13:24 UTC
    sorry but no.

    Unless you write a program to run on their computer, all the perl is strictly server side.
    You might manage it with javascript.
Re: Pop-Up Ads
by screamingeagle (Curate) on Jan 22, 2002 at 09:14 UTC
    Here's a ready-made app which will do the job for u (not sure if its freeware or shareware)
    Pop-Up Killer