PDA

View Full Version : ctCensorWords


TheMayhem
05-12-2010, 12:03 AM
I have discovered a bug within my product and honestly don't know how to fix it because my knowledge of strings is somewhat limited and I can't find how vBulletin does it with their product.

Currently, I know that vBulletin stores a censored words field within the datastore table called ctCensorWords. This field is represented in php as:

$vbulletin->options['ctCensorWords']

The purpose is to check a string for a number of potential words, characters, or phrases that are seperated by spaces and return a value if it finds a censored word within the phrase. The phrase variable I have is called $customtitle. I wasn't able to find the vBulletin coding to see how vBulletin does it, but my question is how can I check my variable phrase of $customtitle and see if it matches any of the words in ctCensorWords?