Forum Moderators: coopster

Message Too Old, No Replies

Parsing mesages for spam

         

AthlonInside

1:59 pm on May 28, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



When dealing with accepting text message (such as in guestbook and forum) we are dealing with all sort of people that will submit all sort of funny things.

Some like to repeat chracters, llllllllllliiiiiiiiiiiiikkkkkkkkkkkkkkeeeeeeeeeee this.

How could I have a function that could take care of this? At least wrap it at certain lenght so it won't screw up the display?

dreamcatcher

3:49 pm on May 28, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



If its a PHP board, the general syntax for word wrapping is as follows:

$text = "A long woooooooooooooooooooooord.";
$newtext = wordwrap( $text, 8, "\n", 1);

echo "$newtext\n";

:)

AthlonInside

5:37 pm on May 29, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Thanks for that!~:)