replace all cases

Results 1 to 2 of 2

Thread: replace all cases

  1. #1
    Join Date
    Dec 1969

    Default replace all cases

    I want make this page so no foul language can be used. <BR>I currently I am using replace in this manner:<BR>strMsg = Replace(strMsg,"BADWORD","****")<BR>strMsg = Replace(strMsg,"badword","****")<BR>strMsg = Replace(strMsg,"Badword","****")<BR><BR>But I think this still will allow a user to write something like badWord. How can I make it so it checks for all cases for all letters and so someone could not just put an ! at the end of the word and it still accepts?<BR><BR>Thank you.

  2. #2
    Join Date
    Dec 1969

    Default RE: replace all cases

    Well there is prob. a better way.<BR><BR>My 1st thought. make a copy of string, uppercase it, check for badwords using instr .<BR><BR>if the instr is tripped, cut that part out of the string<BR><BR>but, that is prob more difficult than its worth.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts