Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re: Robust Anti-Swear script

by mikfire (Deacon)
on Jul 31, 2001 at 01:29 UTC ( [id://100977]=note: print w/replies, xml ) Need Help??


in reply to Robust Anti-Swear script

Warning: This answer may well be off topic
<soapbox=on mode="free speech">
Umm, are you sure about this? What if somebody says "I had to brush it off"? Will your software filter that? If you code it to avoid phrases like this, will you allow the "tithe"? How about "Shiite"?

I could likely sit here all day and come up with silly examples as to how this filtering scheme will filter more than you intended.

I could also show clever ways to still swear that most people would understand. I will not, however, profane the Monastery in that fashion.

What about historical references? How many of us, as we get ready to press the rest button and reinstall the server have shouted "damn the torpedoes, men!"? okay, I will admit I am likely to be in a minority on that one :)

My understanding is that most languages are far to context dependant for this kind of filter to work. I also freely admit this in no way helps answer your question, but I firmly believe there is no solution beyond compiling a list of Carlin's Seven Dirty Words and using a word boundary regex - like

/\bdamn\b/
Sorry 'bout that. We now return you to our regularly scheduled Monastery.
</soapbox>
Update: I really must stop trying to respond using Opera. mikfire

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://100977]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others examining the Monastery: (4)
As of 2025-06-19 12:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.