Closed (fixed)
Project:
SpamSpan filter
Version:
7.x-1.1-beta1
Component:
User interface
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
9 Dec 2008 at 16:15 UTC
Updated:
8 Nov 2014 at 06:18 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
osopolar+ subscribing
And may you also add a option that allows to show a help which says "replace [at] by @ and [dot] by ." and hide this help with js. ... otherwise I don't think my grand parents will be able to send me a mail ;)
Comment #2
naught101 commented+1, if only because I want to remove the spaces...
Comment #3
pentike commentedHi!
This patch adds a field to the admin page where the user can set the "[dot]" text just like the "[at]".
The patch is against 5.x-1.4
Hope it will be useful :)
Cheers, Gábor
www.zeneszapro.hu
Comment #4
naught101 commentedThanks Gábor,
I'm working on getting this to work with drupal six, and it does when javascript is off, but when it's on, it doesn't replace the new "." replacement properly (because it's looking for "[dot]" instead).
here's the .module patch for 6.x, I'll see if I can fix the js problem.
Comment #5
naught101 commentedOk, this patch also draws the spamspan_dot variable into Drupal.settings.spamspan.p (for period, or point), and uses that in the javascript file to create a regex string to to be replaced (globally).
I tried to re-compress the .js, but it didn't end up on a single line... anyway, it works now.
Comment #6
pentike commentedHi!
I have backported your patch to 5.x-1.4, but found that when the replacement string contains some regex characters [ ] { }, the js fails.
I found a code at http://simonwillison.net/2006/Jan/20/escape/ what escapes these strings properly. Maybe this would be a nice functionality in core as well (maybe it's already there, but i could not find it).
This patch is for 5.x-1.4
Cheers, Gábor
www.zeneszapro.hu
Comment #7
naught101 commentedI can't get that to work for 6, probably because I don't know much javascript, and I'm doing something wrong.
Also, you need to switch these lines around:
Otherwise if the regex has a space in it, it won't match.
Comment #8
einkahumor commented+1 on [dot] replacement and translation support. Getting that committed to the 6.x and 7.x versions would make this module very, very neat.
Comment #9
Vayira commentedThis is very necessary to make the module useful in different languages [dot] doesn't mean anything in Spanish.
Comment #10
osopolarBased on the patch in #6 of pentike I created a new one for drupal 6.
Comment #11
atumosucav commented+1
Comment #12
fox mulder commentedHi all!
I have made a patch for D7 to solve this problem. I'm not a programmer, use the patch your own risk (works for me). Any suggestions are welcome.
My motivation: if the site mail contains more dots ( e.g. some.thing [at] so.me.thing ) and this mail address appears on a lots of, or all pages of the site, than google understands the word 'dot' as the one of the most important keyword. Overwriting the 'dot' provides a chance to use relevant keyword instead of 'dot'.
PS: Use #13 instead of this...
Comment #13
fox mulder commentedThis version of the latest patch contains an admin setting page to set the default dot replacement ( /admin/config/content/spamspan )
Comment #14
peterx commentedI added code to beta 4 from the site I am working on. You can replace the dot in the filter page where you change the @.
Comment #15
peterx commented