codetoad.com
  ASP Shopping CartForum & BBS
  - all for $20 from CodeToad Plus!
  
  Home || ASP | ASP.Net | C++/C# | DHTML | HTML | Java | Javascript | Perl | VB | XML || CodeToad Plus! || Forums || RAM 
Search Site:



Javascript Swear Word Filter

Article by: Premshree Pillai (8/16/2002)
Bookmark us now! Add to Favourites
Email a friend!Tell a friend
Summary: This JavaScript is a "Word Filter". It is a type of form validator. When the user submits some text, the validator will check the text for words that has to be filtered.
Viewed: 102529 times Rating (28 votes): 
 4.8 out of 5
 Rate this Article  Read Comments  Post Comments

Javascript Swear Word Filter



This JavaScript is a "Word Filter". It is a type of form validator. When the user submits some text, the validator will check the text for words that has to be filtered.

The words that have to be filtered must be added to the array swear_words_arr. When the user types the text and hits the submit button, if the text contains any word that is present in the array swear_words_arr, the form will not be submitted.

The script can be used for validation of swear words etc.

Place the following code in the head tag of your page.

Select All Code


Now here's the form:

Select All Code







CodeToad Experts

Can't find the answer?
Our Site experts are answering questions for free in the CodeToad forums
Rate this article:     Poor Excellent
View highlighted Comments
User Comments on 'Javascript Swear Word Filter'








Recent Forum Threads
• SoftIce Driver Suite 3.0.1
• metrowerks codewarrior 9.0
• Mapinfo.Professional.v7.0
• GardenGraphics DynaSCAPE Professional 3.02
• Embroidery Great Notions 2004 part01-74
• EFI_BEST_COLORPROOF_V5.0
• AViD.SOFTiMAGE.XSi.V4.2.CD1-NNiSO
• AUTOFX.PHOTOGRAPHIC.EDGES.6.0.CD1
• 0 STI.SASSPro.v2.0.0.2 working full


Recent Articles
ASP GetTempName
Decode and Encode UTF-8
ASP GetFile
ASP FolderExists
ASP FileExists
ASP OpenTextFile
ASP FilesystemObject
ASP CreateFolder
ASP CreateTextFile
Javascript Get Selected Text


© Copyright codetoad.com 2001-2014