The problem with this is that you have to match whole words, otherwise, for example, "Scunthorpe" would get filtered because it contains the substring "cxxx".
You also have perfectly normal words, such as "cxxx" (male hen) which some lists contain. I came across this one (no pun intended) on
as the list was far too restrictive. Also "txxx" (the birds) might get filtered out.
You also have multi languages to take into account (check out
and many other factors.
As well as that, uses can easily modify characters (e.g. "sxxx", "w@nk", etc) or even just use "?", "*", or "!" to replace characters.
I guess it depends on how restrictive you want to be, and who your target audience is (very restrictive for kids, not so for adults).
I reckon if you match whole words only and have a big list that doesn't include words with "clean" meanings, that's a good start.
Hope this helps,
Dan
Coedit Limited - Delivering standards compliant, accessible web solutions
[tt]Dan's Page [blue]@[/blue] Code Couch
[/tt]