Results 1 to 2 of 2

Thread: How to check if a bad word is present in a string using PHP

  1. #1
    Join Date
    Mar 2012
    Posts
    4

    idea How to check if a bad word is present in a string using PHP

    I am developing a script for a website where user activity will be high and every possibility to post abbusive content and bad words. I have a list of all bad words and I need a function which checks if any of the badword from the list is present in the string passed to the function. Can some one help?

  2. #2
    Join Date
    Nov 2011
    Posts
    659

    Re: How to check if a bad word is present in a string using PHP

    I think that you will have to do the same by writing the below codes for those specific words:
    <?php
    $a = 'Where are you xyz';

    if($a contain 'xyz')
    echo 'true';
    ?>

Similar Threads

  1. Check Box in Word (Office 2007)
    By Hynala in forum Vista Help
    Replies: 4
    Last Post: 08-05-2012, 11:19 AM
  2. Program to check whether two string are equal or not
    By seema_thk in forum Software Development
    Replies: 3
    Last Post: 30-11-2009, 01:32 PM
  3. How to check java string not null or blank
    By Capper in forum Software Development
    Replies: 4
    Last Post: 30-07-2009, 07:11 PM
  4. SQL need to check null or empty string
    By B_Hodge in forum Software Development
    Replies: 3
    Last Post: 18-06-2009, 11:44 AM
  5. Searching occurence of a word or string from the database?
    By Gauresh in forum Software Development
    Replies: 4
    Last Post: 18-02-2009, 08:01 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Page generated in 1,711,703,231.53095 seconds with 17 queries