<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
    <channel>
        <title>Using censor bad words function externaly?</title>
        <description> Hi,

I&amp;#039;m currently building a site and have integrated Phorum&amp;#039;s user login/registration features. I&amp;#039;ve got to say Phorum and it&amp;#039;s api rocks, so thanks guys!

What I&amp;#039;m hoping to do is use Phorum&amp;#039;s censor/bad words filter outside of the forum, in order to filter user generated content across the site. While I could code my own functions and use Phorum&amp;#039;s word table, I would like to use the tried and tested functions already written by the Phorum team. No sense trying to re-invent the wheel!

Has anyone done this or got any ideas?

Cheers!</description>
        <link>https://www.phorum.org/support/read.php?28,133333,133333#msg-133333</link>
        <lastBuildDate>Wed, 18 Nov 2026 08:58:18 -0600</lastBuildDate>
        <generator>Phorum 6.0.4</generator>
        <item>
            <guid>https://www.phorum.org/support/read.php?28,133333,133341#msg-133341</guid>
            <title>Re: Using censor bad words function externaly?</title>
            <link>https://www.phorum.org/support/read.php?28,133333,133341#msg-133341</link>
            <description><![CDATA[ Hi Maurice,<br />
<br />
Thanks for pointing me in the right direction.<br />
<br />
I&#039;ll get it working and post the code here.<br />
<br />
Thanks again!]]></description>
            <dc:creator>Stuart</dc:creator>
            <category>Phorum Integration</category>
            <pubDate>Mon, 22 Sep 2008 11:08:24 -0500</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?28,133333,133335#msg-133335</guid>
            <title>Re: Using censor bad words function externaly?</title>
            <link>https://www.phorum.org/support/read.php?28,133333,133335#msg-133335</link>
            <description><![CDATA[ Thanks for your compliments and welcome to the happy Phorum user bunch!<br />
<br />
On your question: you could use Phorum&#039;s format function, which includes censor list formatting. But mind that you will get all other Phorum formatting as well. If you don&#039;t want that, then you might have to do something like assigning an empty array to $PHORUM[&#039;hooks&#039;] before calling the formatting function.<br />
<br />
Some basic code for including the Phorum code and using its formatting (beware of undefined index warnings; I didn&#039;t test the code and the $fake_messages elements might need some more fields):<br />
<br />
[code=&quot;php&quot;]<br />
$body = &#039;your text that has to be censored&#039;;<br />
<br />
chdir(&#039;/your/phorum/install/dir&#039;);<br />
include(&#039;common.php&#039;);<br />
require_once(&#039;include/format_functions.php&#039;);<br />
 <br />
$fake_messages = array( 1 =&gt; array( &#039;body&#039; =&gt; $body, &#039;subject&#039; =&gt; &#039;&#039; ) );<br />
$formatted_messages = phorum_format_messages($fake_messages);<br />
$formatted_body = $formatted_messages[1][&#039;body&#039;];<br />
[/code]<br />
<br />
I hope this helps.]]></description>
            <dc:creator>Maurice Makaay</dc:creator>
            <category>Phorum Integration</category>
            <pubDate>Mon, 22 Sep 2008 10:35:12 -0500</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?28,133333,133333#msg-133333</guid>
            <title>Using censor bad words function externaly?</title>
            <link>https://www.phorum.org/support/read.php?28,133333,133333#msg-133333</link>
            <description><![CDATA[ Hi,<br />
<br />
I&#039;m currently building a site and have integrated Phorum&#039;s user login/registration features. I&#039;ve got to say Phorum and it&#039;s api rocks, so thanks guys!<br />
<br />
What I&#039;m hoping to do is use Phorum&#039;s censor/bad words filter outside of the forum, in order to filter user generated content across the site. While I could code my own functions and use Phorum&#039;s word table, I would like to use the tried and tested functions already written by the Phorum team. No sense trying to re-invent the wheel!<br />
<br />
Has anyone done this or got any ideas?<br />
<br />
Cheers!]]></description>
            <dc:creator>Stuart</dc:creator>
            <category>Phorum Integration</category>
            <pubDate>Mon, 22 Sep 2008 10:25:51 -0500</pubDate>
        </item>
    </channel>
</rss>
