Previous Thread
Next Thread
Print Thread
Rate Thread
Joined: Jul 2002
Posts: 19
B
bud Offline
Newbie
Offline
Newbie
B
Joined: Jul 2002
Posts: 19
Sure.

1. Make a backup of sendmessage.php and mess_reply.php
2. Add the following code beneath line 123 in sendmessage.php
3. Add the same code beneath line 100 in mess_reply.php

Code
<br />// ---------------------------------------------------------------------<br />// Substitute any filters/badwords with the $config[censored] variable in the <br />//  message or subject   <br />   $words[0] = "";   <br />   if ($config['censored']) {<br />       $badwords = @file("{$config['path']}/filters/badwords");<br />       if (!is_array($badwords)) {<br />       	  $badwords = @file ("{$config['phpurl']}/filters/badwords");<br />       }<br />       while (list($linenum,$line) = each($badwords) ) {<br />          $line = chop($line);<br />          if ( (preg_match("/^\r/",$line)) || (preg_match("/^\n/",$line)) ) {<br />          	continue;<br />       }<br />       $islines = 1;<br />       $words[count($words)] = $line;<br />       // PHP4 ONLY         <br />       // array_push ($words, $line);      <br />   }<br />   if ($islines) {         <br />       $badwords = join("|", $words);<br />       $badwords = preg_replace("/^\|/","",$badwords);<br />       <br />       $Message = preg_replace("/\b($badwords)\b/i",$config['censored'],$Message);<br />       $Subject = preg_replace("/\b($badwords)\b/i",$config['censored'],$Subject);<br />       }<br />   }<br />   $FormBody = $Message;<br />   $FormSubject = $Subject;<br />

Sponsored Links
Entire Thread
Subject Posted By Posted
Bad words on signature. How to remove? ehm 01/08/2003 5:43 PM
Re: Bad words on signature. How to remove? bud 01/08/2003 7:07 PM
Re: Bad words on signature. How to remove? ehm 01/09/2003 6:08 AM
Re: Bad words on signature. How to remove? Beentheredonethat 01/10/2003 3:42 PM
Re: Bad words on signature. How to remove? bud 01/13/2003 10:01 PM

Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
Bill B
Bill B
Issaquah, WA
Posts: 87
Joined: December 2001
Forum Statistics
Forums63
Topics37,551
Posts293,823
Members13,839
Most Online5,166
Sep 15th, 2019
Today's Statistics
Currently Online 267
Topics Created 0
Posts Made 0
Users Online 0
Birthdays 2
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,808
Greg Hard 4,625
Top Posters(30 Days)
isaac 5
Top Likes Received
isaac 64
Gizmo 12
Brett 7
Morgan 2
Top Likes Received (30 Days)
isaac 2
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2020 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 7.7.6
(Snapshot build 20201121.dev)
Responsive Width:

PHP: 5.4.45 Page Time: 0.500s Queries: 18 (0.474s) Memory: 3.2928 MB (Peak: 3.4623 MB) Data Comp: Zlib Server Time: 2020-12-03 00:18:21 UTC
Valid HTML 5 and Valid CSS