Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.6 > vBulletin 3.6 Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Replacement Words In Posts Details »»
Replacement Words In Posts
Version: 1.00, by harmor19 harmor19 is offline
Developer Last Online: May 2023 Show Printable Version Email this Page

Category: Administrative and Maintenance Tools - Version: 3.6.4 Rating:
Released: 06-06-2007 Last Update: Never Installs: 122
Uses Plugins
 
No support by the author.

A few members were asking for a better censor system when it came to replacing bad words with good words.

This hack will replace any word you specify even if the word in question is typed with random uppercase and lowercase letters.
It still can be circumvented but I guess that's why you have moderators.


Installing
Download the product XML. Go into to your ACP --> Plugins & Products --> Manage Products click "[Add/Import Product]". Browse to product-ah_word_replace.xml and click "Import".

Settings
ACP --> vBulletin Options --> Censorship Options
There should be two new options titled "Word Replacements (Find)" and "Word Replacements (Replace)".

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #92  
Old 11-21-2007, 04:31 AM
Pocket Aces Pocket Aces is offline
 
Join Date: Mar 2007
Posts: 128
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Would be nice if it affects thread title as well and pls. fix the lowercase issue.
Reply With Quote
  #93  
Old 11-25-2007, 11:38 PM
mri_mohammad mri_mohammad is offline
 
Join Date: Feb 2007
Posts: 46
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

not working it's make my website down on 3.6.8
Reply With Quote
  #94  
Old 12-24-2007, 01:40 PM
Foxtrotelite Foxtrotelite is offline
 
Join Date: Mar 2007
Posts: 56
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

any chance of an update for 3.6.8 or maybe 3.7?
Reply With Quote
  #95  
Old 01-05-2008, 05:27 PM
BigKev45 BigKev45 is offline
 
Join Date: Mar 2007
Posts: 5
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

have it installed and i was hoping i could replace it with a vb code smiley but it just shows up w/ the code and no smiley for example if i want to replace dog it shows :censored: instead of the smiley that is attached to this code
Reply With Quote
  #96  
Old 01-13-2008, 12:48 AM
Big Kahuna's Avatar
Big Kahuna Big Kahuna is offline
 
Join Date: Feb 2002
Location: SE Texas
Posts: 182
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I installed it on 3.6.8 and it works -- except it changes any upper case letter (like the first letter of the first word of a sentence) to lowercase. Had to disable until I find out that there is a fix -- of the I have to uninstall.
Reply With Quote
  #97  
Old 01-13-2008, 09:04 PM
AcidX's Avatar
AcidX AcidX is offline
 
Join Date: Jan 2006
Location: Macedonia
Posts: 137
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Doesn't work for me, using 3.6.3.
Reply With Quote
  #98  
Old 01-18-2008, 12:01 PM
craiovaforum's Avatar
craiovaforum craiovaforum is offline
 
Join Date: Nov 2005
Location: Craiova
Posts: 128
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I recomment that you modify your plugin and use str_ireplace instead of doing a strtolower to the whole post message because its simply wrong.
Your plugin changes all posts to lowercase.

Of course, str_ireplace isnt the ideal way to handle utf-8 strings but its better than what you use in any case.
Reply With Quote
  #99  
Old 01-20-2008, 03:36 PM
ballpnet ballpnet is offline
 
Join Date: Oct 2007
Posts: 6
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Greetings,

I've changed the code within the plugin in order to get it to work at our forums. This works with 3.6.8 and I've not tested it on any of the other versions. If anyone else wants to make the same modifications they are more than welcome to do so, but please be advised that it'll be at your own discretion and I will not provide support or be held liable if anything goes wrong.

*Props goes to mah man Nate(nathanledet) for bringing this plugin to our attention.*

Things the modification fixes:
1)It does not lower case the entire message
2)It tries to uppercase the first letter of a word at the beginning of a sentence. Say for example you want to replace the uppercase word WIDGET with widget. If someone begins the sentence with this word, then it'll look awkward and incorrect when it gets lowercased. The code then corrects this by uppercasing the "w" and giving us a correct much better looking "Widget."

Find and replace the <phpcode> opening and closing tags with the following.

PHP Code:
<![CDATA[$array1 explode("|"$vbulletin->options['ah_word_replace_find']);

$array2 explode("|"$vbulletin->options['ah_word_replace_replace']);

$ah_text $this->post['message'];

$breadcrumb = array();

if(
count($array1) > 0) {

  for(
$j=0$j<count($array1); $j++) {
    
$breadcrumb[] = '/'.$array1[$j].'/i';
  }

  
$ah_text preg_replace($breadcrumb$array2$ah_text);

  
$separators = array('. ''? ''! ');
  
  for(
$i=0$i<count($separators); $i++) {

    
$var $separators[$i];
    
$sentences explode($var$ah_text);
    
$tmp_sentence '';
    
$k 0;
    foreach(
$sentences as $single_sentence) {
    
$tmp_sentence .= ucfirst($single_sentence);

     if (
$k<count($sentences)-1) {
          
$tmp_sentence .= $var;
        }
        
$k++;
    }
    
$ah_text $tmp_sentence;
  }
}

$this->post['message'] = $ah_text;]]> 
Reply With Quote
  #100  
Old 01-20-2008, 04:18 PM
NathanLedet NathanLedet is offline
 
Join Date: Nov 2005
Posts: 85
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Works great!! :up:
Reply With Quote
  #101  
Old 01-20-2008, 08:34 PM
satanreborn satanreborn is offline
 
Join Date: Dec 2007
Posts: 2
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

still cant get it to work, even with the updated php... running vBulletin 3.6.8 Patch Level 2
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 12:57 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.09044 seconds
  • Memory Usage 2,315KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_php
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete