Hello, I have a website that's create a search history, but some users search for "pr0n" and i don't want that the search history show it in the homepage.
I know how to do it for a single keyword, example:
PHP Code:
<?
require_once("includes/config.php");
// Delete Bobby from the "example" MySQL table
mysql_query("DELETE FROM history WHERE query='sex")
or die(mysql_error());
?>
But it will just delete the query "sex" and don't "sex-tape", "sex-anything" or "sex-example".
What I want do is create a badwords list and ANY query if include this words in the query will be deleted via cronjobs.
"Fast" don't will delete just the query "Fast" but the queries "Fast", "Fast-job" or "Fast-anything".
|