[thelist] stripping emails and replacing with forms to combat spam

Dan Stockton prosayist at yahoo.com
Thu Sep 26 13:19:01 CDT 2002


>Hi All
hey!
>I am starting today with a mission of action.
good plan ANYday :)
> I would like to know what you guys think of this.
.. shoot
>Having embedded many contact email addreses within sites for all the right
>and possitive reasons.  The point has come where spam spam spam has just
>sprialled out of control.
happens to the best of us
>So the plan is this.  To remove all email addresses from sites and replace
>them with a contact form.
yeah, that's one way to do it
>The question(s) is/are.  Is this going to stop/reduce spam
>(in the long term)
my answer(s) is/are 'yes' as spambots (AFAIK and judging from the
information concluded in my own recent studies into this matter) scan the
html for anything that say "href=mailto:".. k, sorry for interrupting; go
on...
>and will this be a more effective way for people to make
>contact for whatever reason(s)?
my answer(s) to this part of the two-part question would also be 'yes' (in
mY case) as I (for one) would much rather fill in a form than open up my
mail

what I've done (am currently doing?) is a PHP function:

FUNCTION MAILTO($MAILTOADDRESS){
$ADD_RESS=STR_REPLACE('.',' dot ',STR_REPLACE('@',' at ',$MAILTOADDRESS));
$ENCODEDADDRESS=URLENCODE($MAILTOADDRESS);
$MAIL_TO_ADDRESS=STR_REPLACE('@',' at ',$MAILTOADDRESS);
PRINT"<script type=\"text/javascript\" language=\"javascript\">
var a, s, n;
function ScReWuPtHeSpAmBoTs(s)
{r='';for(i=0;i<s.length;i++){n=s.charCodeAt(i); if (n>=8364) {n = 128;} r
+= String.fromCharCode( n - 3 ); }return r;}
a =\"?d#rqIrfxv@%li+wklv1eoxu,wklv1eoxu+,%#kuhi@%pdlowr=\";
document.write (ScReWuPtHeSpAmBoTs(a));
</script>$ENCODEDADDRESS\" title=\"Send Mail To: ".$MAIL_TO_ADDRESS."\"
/>".$ADD_RESS."</a>";}

Calling this function as MAILTO(user at domain.tld) would produce:
<script type="text/javascript" language="javascript">
var a, s, n;
function ScReWuPtHeSpAmBoTs(s)
{r='';for(i=0;i<s.length;i++){n=s.charCodeAt(i); if (n>=8364) {n = 128;} r
+= String.fromCharCode( n - 3 ); }return r;}
a ="?d#rqIrfxv@%li+wklv1eoxu,wklv1eoxu+,%#kuhi@%pdlowr=";
document.write (ScReWuPtHeSpAmBoTs(a));
</script>user%domain.tld" title="Send Mail To: user at domain.tld" />user at
domain dot tld</a>
(but it actually functions as <a href=mailto:user at domain>)

.. you could also use another language (ASP,CFM.. ) or you could just do it
manually! The most important part of this is the javascript function
'ScReWuPtHeSpAmBoTs(s)'

__________________________________________________
Do you Yahoo!?
New DSL Internet Access from SBC & Yahoo!
http://sbc.yahoo.com



More information about the thelist mailing list