[FREE] Easy Auto-Link + Bad Words Replacer - Wordpress Script
Yeah!!!
I got an exclusive Script for you WordPress Bloggers :D
The first Script is an Bad words replacer script for Wordpress...
I have added already bad words which will replace it automatically!
It is very useful for people who runs an DoFollow Article Directory Submitter Website with Wordpress or accept guest post.
Its very useful to avoid to get banned from google adsense cause you using bad words in your post.
Okay here we go with the first one:
its the Auto Link Script:
Its the same script with only a simple html linkcode inside...
just copy & paste it in functions.php
I made an preview with only 3 Keywords and links... but its possible to add more urls and keywords.
Code:
function replace_text_wps($text){
$replace = array(
// 'WORD TO REPLACE' => 'REPLACE WORD WITH THIS'
'KEYWORD' => '<a href="http://www.domain-name.com/" title="KEYWORD">KEYWORD</a>',
'KEYWORD' => '<a href="http://www.domain-name.com/" title="KEYWORD">KEYWORD</a>',
'KEYWORD' => '<a href="http://www.domain-name.com/" title="KEYWORD">KEYWORD</a>',
);
$text = str_replace(array_keys($replace), $replace, $text);
return $text;
}
add_filter('the_content', 'replace_text_wps');
add_filter('the_excerpt', 'replace_text_wps');
Here is the Bad Words Replacer Script...
I already added some important keywords inside which google adsense dont like!
You can add more.. of course!
Quote:
Originally Posted by
wink0r
You should add the word 'boob' in there. I have a page that no longer has Adsense, but when it did it only got one public service ad on the page (out of three ad slots). In context the word meant one who makes frequent mistakes and had no sexual connotation at all, but it is obviously on their bad words list.
PS: You could just replace the second 'sex' with 'boob'. The filter won't find 'sex' on the second pass anyway.
... FIXED!
(there are some words like p*orn or V*iagra this forum automatically displayed. So you must add these words inside by yourself)
Code:
function replace_text_wps($text){
$replace = array(
// 'WORD TO REPLACE' => 'REPLACE WORD WITH THIS'
'boob' => '*Censored!*',
'boobs' => '*Censored!*',
'viagra' => '*Censored!*',
'fuck' => '*Censored!*',
'fucking' => '*Censored!*',
'nigga' => '*Censored!*',
'bitch' => '*Censored!*',
'bastard' => '*Censored!*',
'erection' => '*Censored!*',
'mastrubation' => '*Censored!*',
'penis' => '*Censored!*',
'faggot' => '*Censored!*',
'pills' => '*Censored!*',
'pedophile' => '*Censored!*',
'pussy' => '*Censored!*',
'ass' => '*Censored!*',
'schlong' => '*Censored!*',
'xx' => '*Censored!*',
'xxx' => '*Censored!*',
'casino' => '*Censored!*',
'poker' => '*Censored!*',
'las vegas' => '*Censored!*',
'gambling' => '*Censored!*',
'drugs' => '*Censored!*',
'cocaine' => '*Censored!*',
'heroin' => '*Censored!*',
'dildo' => '*Censored!*',
'vibrator' => '*Censored!*',
'marijuana' => '*Censored!*',
'black hat seo' => '*Censored!*',
'warez' => '*Censored!*',
'pharmacy' => '*Censored!*',
'piss' => '*Censored!*',
'shit' => '*Censored!*',
'facial' => '*Censored!*',
'blowjob' => '*Censored!*',
);
$text = str_replace(array_keys($replace), $replace, $text);
return $text;
}
add_filter('the_content', 'replace_text_wps');
add_filter('the_excerpt', 'replace_text_wps');
ENJOY and dont forget to click on Thanks!