Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Help Groups for Snitz Forums 2000 Users
 Help: General / Current Version (Old)
 Easy solution for Bad Word Filter Problems
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

racerslounge
Starting Member

23 Posts

Posted - 03 June 2001 :  23:07:08  Show Profile  Visit racerslounge's Homepage
Now I am no programmer, but I have figured out the easiest solution for the bad word filter problem. The problem of the filter filtering out parts of other words, like class, mass, pass, etc... where the a-ss would not show.

The solution is simple. In your bad word filter list, place a space in front and after the word you listed to filter. This will cause the filter to only pick the word up by itself.

http://www.racerslounge.com

e3stone
Average Member

USA
885 Posts

Posted - 03 June 2001 :  23:14:18  Show Profile  Send e3stone an AOL message
that would probably work..looking at the old chkBadWords function, there isn't a trim() in it....or just replace the ChkBadWords function in inc_functions.asp with this:

Function ChkBadWords(fString)
Dim regEx, str1 ' Create variables.
str1 = fString
bwords = split(strBadWords, "|")
for i = 0 to ubound(bwords)
Set regEx = New RegExp ' Create regular expression.
regEx.Pattern = "\b" & bwords(i) & "\b" ' Set pattern.
regEx.IgnoreCase = FALSE ' Make case insensitive.
str1 = regEx.Replace(fstring, string(len(bwords(i)),"*"))
do until str1 = fstring
fstring = str1
str1 = regEx.Replace(fstring, string(len(bwords(i)),"*"))
loop
next
ChkBadWords = str1
End Function

<-- Eric -->


http://insidewaco.com/forum/home.asp
Go to Top of Page

HuwR
Forum Admin

United Kingdom
20584 Posts

Posted - 04 June 2001 :  08:07:11  Show Profile  Visit HuwR's Homepage
quote:

that would probably work..looking at the old chkBadWords function, there isn't a trim() in it....or just replace the ChkBadWords function in inc_functions.asp with this:

Function ChkBadWords(fString)
Dim regEx, str1 ' Create variables.
str1 = fString
bwords = split(strBadWords, "|")
for i = 0 to ubound(bwords)
Set regEx = New RegExp ' Create regular expression.
regEx.Pattern = "\b" & bwords(i) & "\b" ' Set pattern.
regEx.IgnoreCase = FALSE ' Make case insensitive.
str1 = regEx.Replace(fstring, string(len(bwords(i)),"*"))
do until str1 = fstring
fstring = str1
str1 = regEx.Replace(fstring, string(len(bwords(i)),"*"))
loop
next
ChkBadWords = str1
End Function

<-- Eric -->


http://insidewaco.com/forum/home.asp


This solution only works for certain versions of the scripting engine, and may not be supported by your host

Go to Top of Page

e3stone
Average Member

USA
885 Posts

Posted - 04 June 2001 :  08:19:10  Show Profile  Send e3stone an AOL message
This is the one that lets you spell your last name, right? Just making sure I posted the right one

<-- Eric -->


http://insidewaco.com/forum/home.asp
Go to Top of Page

mrWize
deleted

119 Posts

Posted - 04 June 2001 :  08:34:44  Show Profile
If the host don´t have the latest scripting engine I wouldn´t choose that host.

Upgrading to newer engines take out some bugs too from older versions.

cya,
//mrWize

Go to Top of Page

mrWize
deleted

119 Posts

Posted - 04 June 2001 :  08:36:15  Show Profile
and one thin more ...

could script to ceck for the engine version and if its Not a 5.x version ... use another function.

in strConnString uses newer versions of MDAC for example .. so, shouldn+t the forum also use a newer engine too?

cya again,
//mrWize

Go to Top of Page

racerslounge
Starting Member

23 Posts

Posted - 05 June 2001 :  01:19:03  Show Profile  Visit racerslounge's Homepage
It works. I am using it now. Just put a space in front and after the word in your badword list in the administrator section. It will only pick up the word itself.

http://www.racerslounge.com

Edited by - racerslounge on 05 June 2001 01:19:44
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.32 seconds. Powered By: Snitz Forums 2000 Version 3.4.07