<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
    <channel>
        <title>Module: Automatic Message Pruning</title>
        <description> This module allows an admin to automatically close, hide, or delete posts in selected forums after a selected period of time.  Each forum can be configured individually.  Sticky posts can be excluded.

Settings:
On the settings page for this module you can set each forum to have its own custom actions on selected messages.  You can choose to close, hide, or delete posts based on the age of either the starting topic or the last post in the topic.  You can set any number of hours, days, or months (30 days) after which to process the posts.

You must use a cron job to process posts with this module.  You have two options to do this.  If your host supports cron jobs on your server, you can set your own cron job using the &amp;quot;scheduled&amp;quot; hook.  If your host does not support cron jobs, you can use a third party service, such as www.setcronjob.com or www.cronless.com.  I don&amp;#039;t endorse any particular service and others can be found on Google with a search for &amp;quot;free cron jobs.&amp;quot;

In either case, I would advise running the cron job once per hour.  If your site receives more than 1000 posts per hour and you are having posts automatically deleted then the cron job should be run more often.

Setting up a Cron Job on Your Server:
Your hosted cron job should call the Phorum &amp;quot;scheduled&amp;quot; hook from the Phorum script.php file.  The module will handle any time-outs or errors which otherwise could cause the cron job to run two instances of this module.  This is one example cron job:

0 * * * * cd your/phorum/root &amp;amp;&amp;amp; /usr/bin/php ./script.php --scheduled

There should be no output from this script unless there is an error.  If possible I would also advise that you have the output from this script either logged or emailed.

Setting up a Cron Job Through a Third Party Service:
Each third party service will have its own setup instructions but all of them should ask for a url which will be opened on a regular schedule.  The url to use for this module is provided at the top of the settings page.  Simply highlight and copy the entire url in the text box.  This url includes a unique certificate for your site, generated the first time you open the settings page.

Todo:
- Add features as they are requested.</description>
        <link>https://www.phorum.org/support/read.php?62,146707,146707#msg-146707</link>
        <lastBuildDate>Sun, 13 Sep 2026 15:42:19 -0500</lastBuildDate>
        <generator>Phorum 6.0.4</generator>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,154594#msg-154594</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,154594#msg-154594</link>
            <description><![CDATA[ Hello,<br />
<br />
we just tested this module to hide messages in one of our forums. We could also access the hidden messages from the control center. So far the module is working fine. We did hide all messages. This particular forum is empty now, as intended.<br />
<br />
There is only one error; on the list page, the number of themes are set to &quot;0&quot; (correct), but the number of messages are still showing with the old count. The date of the last post is Dec. 31, 1969 12:00. Even after deleting some of the messages by accessing the control center and go to unapproved messages &gt; delete, the count stays the same.<br />
<br />
Can we adjust this ? If so, where would we have to look ?<br />
The counts on the forum&#039;s read page is correct, none at all.<br />
<br />
One addition: After creating one new thread, the thread count on the list page jump from &quot;0&quot; to 6. The count of messages went up by one and the date is showing correct for the last message.<br />
The forum&#039;s read page is showing the correct numbers, 1 thread, 1 message, dte and clicks correct.<br />
<br />
Find the attached list view.<br />
<br />
Johannes]]></description>
            <dc:creator>gelbeseiten</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Wed, 13 Nov 2013 19:54:42 -0600</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,150778#msg-150778</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,150778#msg-150778</link>
            <description><![CDATA[ did you check the unapproved messages panel in the controlcenter.]]></description>
            <dc:creator>Thomas Seifert</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Fri, 06 Jan 2012 01:31:35 -0600</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,150773#msg-150773</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,150773#msg-150773</link>
            <description><![CDATA[ Thank you!<br />
installed and worked at once:)<br />
exactly what i needed for just one of my phorums.<br />
<br />
one little question: because of safety reasons i have set the action to hide instead of deletion.<br />
<br />
But now de hidden messages are really hidden,i can&#039;t find a way to delete hidden messages?]]></description>
            <dc:creator>Terradon</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Thu, 05 Jan 2012 23:16:13 -0600</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,149978#msg-149978</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,149978#msg-149978</link>
            <description><![CDATA[ Would you be so kind as to add an option to Re-Open topics as well.<br />
<br />
The use case for this would be if the administrator chose a duration in which to close topics, and later wanted to broaden it - or simply changed his mind altogether.]]></description>
            <dc:creator>Robert Angle</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Tue, 01 Nov 2011 00:22:52 -0500</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,147007#msg-147007</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,147007#msg-147007</link>
            <description><![CDATA[ <blockquote class="bbcode"><div><small>Quote<br /></small><strong>Joe Curia</strong><br />
Bill,<br />
<br />
Please try the attached settings.php in place of the original.  If this works, than the large number of forums you have is causing this module to exceed the storage capacity for settings in Phorum.  This workaround should fix the problem for you as you are only pruning a few of your forums.  If it does work, I will need to code a better way to store those settings.<br />
<br />
Anyways, please upload the attached file and try to save your settings again.  Please let me know what happens, good or bad.<br />
<br />
Thanks for your patience in working out these bugs.</div></blockquote>
<br />
Same result as the last time, it won&#039;t save the setting or reset the cronjob error count after I upload the new settings.php<br />
<br />
But I am willing to work with you as long it take to work the bugs out cause I really need module like this 8-)<br />
<br />
And thank you for taking time to troubleshoot this<br />
<br />
Bill]]></description>
            <dc:creator>CBiLL</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Mon, 29 Nov 2010 14:41:44 -0600</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,146996#msg-146996</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,146996#msg-146996</link>
            <description><![CDATA[ Bill,<br />
<br />
Please try the attached settings.php in place of the original.  If this works, than the large number of forums you have is causing this module to exceed the storage capacity for settings in Phorum.  This workaround should fix the problem for you as you are only pruning a few of your forums.  If it does work, I will need to code a better way to store those settings.<br />
<br />
Anyways, please upload the attached file and try to save your settings again.  Please let me know what happens, good or bad.<br />
<br />
Thanks for your patience in working out these bugs.]]></description>
            <dc:creator>Joe Curia</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Sun, 28 Nov 2010 22:08:46 -0600</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,146995#msg-146995</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,146995#msg-146995</link>
            <description><![CDATA[ <blockquote class="bbcode"><div><small>Quote<br /></small><strong>Joe Curia</strong><br />
Bill,<br />
<br />
I am still looking through the code, trying to find anything that might cause the settings error that your are seeing.  The other error was, as Maurice rightly assumed, a mistake on my part in assuming that the file storage api would be available.  Please upload this patched file to the module&#039;s directory to fix that error.</div></blockquote>
<br />
OK here the picture of an idea what it does when I tried to save the setting for the forums, I only wanted to delete message in my last 3 forums that are older than 6 months along with it attachments.<br />
<br />
The first photo attached show the settings I set up for the last three forums before I click save. I also select to reset error count at the bottom.<br />
<br />
Second photo show the result and you can see that the last forum in the list lost it settings and the error message had not been reset either.<br />
<br />
Third is the strange one .. What I did is put all setting back to default and only set up the last forum that keep losing it settings but this time it kept the setting however it did not keep the setting I choose on &quot;sticky message&quot; and lost that only setting after I saved it.<br />
<br />
Thank you for looking into it and if you need access to my forum to further research on this, send me a PM and I will set you up.<br />
<br />
Bill]]></description>
            <dc:creator>CBiLL</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Sun, 28 Nov 2010 18:09:25 -0600</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,146994#msg-146994</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,146994#msg-146994</link>
            <description><![CDATA[ Bill,<br />
<br />
I am still looking through the code, trying to find anything that might cause the settings error that your are seeing.  The other error was, as Maurice rightly assumed, a mistake on my part in assuming that the file storage api would be available.  Please upload this patched file to the module&#039;s directory to fix that error.]]></description>
            <dc:creator>Joe Curia</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Sun, 28 Nov 2010 17:39:01 -0600</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,146993#msg-146993</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,146993#msg-146993</link>
            <description><![CDATA[ <blockquote class="bbcode"><div><small>Quote<br /></small><strong>Maurice Makaay</strong><br />
It is not related to storing the attachments on disk. The error tells that the file API function is not known. Most likely, the file API layer is not loaded, prior to the offending call.</div></blockquote>
<br />
So is the issue on my server end?  What do you suggest I look into?<br />
<br />
Thank you<br />
<br />
Bill]]></description>
            <dc:creator>CBiLL</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Sun, 28 Nov 2010 16:55:34 -0600</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,146992#msg-146992</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,146992#msg-146992</link>
            <description><![CDATA[ It is not related to storing the attachments on disk. The error tells that the file API function is not known. Most likely, the file API layer is not loaded, prior to the offending call.]]></description>
            <dc:creator>Maurice Makaay</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Sun, 28 Nov 2010 16:20:24 -0600</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,146990#msg-146990</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,146990#msg-146990</link>
            <description><![CDATA[ I wonder if this issue is because I am using Store file on disk module? <br />
<br />
All of our post attachment are storage on disk instead of in DB, we would like to see those attachement deleted along with the posts. it like over 100,000 photos in there is the main reason why we would need this module.<br />
<br />
<br />
Bill]]></description>
            <dc:creator>CBiLL</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Sun, 28 Nov 2010 15:38:28 -0600</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,146987#msg-146987</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,146987#msg-146987</link>
            <description><![CDATA[ I been wanting a module like this to delete messages in some of my forums that are older than 6 months.<br />
<br />
So I downloaded this module and follow instruction but for some strange reason I couldn&#039;t save one of the forum settings and it would error out when I run the script.  When I click Save to save my module settings one of the last forum setting would just get wiped out and go back to default blank setting. <br />
<br />
Here the error message I get when excuting the line<br />
<br />
&lt;br /&gt;&lt;b&gt;Fatal error&lt;/b&gt;: Call to undefined function phorum_api_file_delete() in <br />
<br />
&lt;b&gt;/home/garyk/public_html/mods/automatic_message_pruning/automatic_message_pruning_scheduled.php&lt;/b&gt; on line &lt;b&gt;274&lt;/b&gt;&lt;br /&gt;gar<br />
<br />
<br />
<br />
Bill]]></description>
            <dc:creator>CBiLL</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Sun, 28 Nov 2010 00:40:35 -0600</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,146750#msg-146750</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,146750#msg-146750</link>
            <description><![CDATA[ I guess I would agree with Maurice that this should be a separate module.  Ideally it would create a third &quot;Temporary Sticky&quot; sort option on the posting form.  The admin would then determine how long these types of messages should remain sticky.  After that time, the message would be set to normal through a cron job.  Unfortunately I am back to the weekly grind and it is a busy week on top of that.  I may try hand at this sometime soon, but no promises.]]></description>
            <dc:creator>Joe Curia</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Tue, 09 Nov 2010 08:27:16 -0600</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,146749#msg-146749</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,146749#msg-146749</link>
            <description><![CDATA[ A combination of laziness and semi-stickiness, got it, thanks ;-)]]></description>
            <dc:creator>Maurice Makaay</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Tue, 09 Nov 2010 06:30:06 -0600</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,146748#msg-146748</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,146748#msg-146748</link>
            <description><![CDATA[ maurice,<br />
<br />
the main reason is lazyness :) <br />
&quot;my&quot; moderators use stickies for messages that should stay on top for a limited time, think of them as some kind of reminder. those messages should not be deleted, but &quot;vanish&quot; in the normal posts after a given time. unfortunately, they use it very often and they tend to forget to un-sticky them. so it would be nice to to make them unsticky automatically.]]></description>
            <dc:creator>Lammi</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Tue, 09 Nov 2010 06:26:51 -0600</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,146747#msg-146747</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,146747#msg-146747</link>
            <description><![CDATA[ What would be the use case for that? (just interested about it) It sounds rather contra-conceptual to me. To me, stickies are always manually managed, so I&#039;m interested to know how you use the stickies.<br />
<br />
When module functionality would have to be written, then I think it would be more appropriate as a separate module, than to add it to this message pruning module. The functionalities do not really match IMO. But maybe your use case makes it logical to do so.]]></description>
            <dc:creator>Maurice Makaay</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Tue, 09 Nov 2010 05:09:06 -0600</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,146746#msg-146746</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,146746#msg-146746</link>
            <description><![CDATA[ a nice extra would be the option to &quot;unsticky&quot; sticky notes after a time.]]></description>
            <dc:creator>Lammi</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Tue, 09 Nov 2010 04:04:21 -0600</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,146725#msg-146725</guid>
            <title>Re: Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,146725#msg-146725</link>
            <description><![CDATA[ Installed and running. This one really eases keeping forums tidy for lazy admins like me.<br />
<br />
Thanks again Joe. :)]]></description>
            <dc:creator>Fenix</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Mon, 08 Nov 2010 05:55:54 -0600</pubDate>
        </item>
        <item>
            <guid>https://www.phorum.org/support/read.php?62,146707,146707#msg-146707</guid>
            <title>Module: Automatic Message Pruning</title>
            <link>https://www.phorum.org/support/read.php?62,146707,146707#msg-146707</link>
            <description><![CDATA[ This module allows an admin to automatically close, hide, or delete posts in selected forums after a selected period of time.  Each forum can be configured individually.  Sticky posts can be excluded.<br />
<br />
<b>Settings:</b><br />
On the settings page for this module you can set each forum to have its own custom actions on selected messages.  You can choose to close, hide, or delete posts based on the age of either the starting topic or the last post in the topic.  You can set any number of hours, days, or months (30 days) after which to process the posts.<br />
<br />
You must use a cron job to process posts with this module.  You have two options to do this.  If your host supports cron jobs on your server, you can set your own cron job using the &quot;scheduled&quot; hook.  If your host does not support cron jobs, you can use a third party service, such as www.setcronjob.com or www.cronless.com.  I don&#039;t endorse any particular service and others can be found on Google with a search for &quot;free cron jobs.&quot;<br />
<br />
In either case, I would advise running the cron job once per hour.  If your site receives more than 1000 posts per hour and you are having posts automatically deleted then the cron job should be run more often.<br />
<br />
<b>Setting up a Cron Job on Your Server:</b><br />
Your hosted cron job should call the Phorum &quot;scheduled&quot; hook from the Phorum script.php file.  The module will handle any time-outs or errors which otherwise could cause the cron job to run two instances of this module.  This is one example cron job:<br />
<br />
0 * * * * cd your/phorum/root &amp;&amp; /usr/bin/php ./script.php --scheduled<br />
<br />
There should be no output from this script unless there is an error.  If possible I would also advise that you have the output from this script either logged or emailed.<br />
<br />
<b>Setting up a Cron Job Through a Third Party Service:</b><br />
Each third party service will have its own setup instructions but all of them should ask for a url which will be opened on a regular schedule.  The url to use for this module is provided at the top of the settings page.  Simply highlight and copy the entire url in the text box.  This url includes a unique certificate for your site, generated the first time you open the settings page.<br />
<br />
<b>Todo:</b><br />
- Add features as they are requested.]]></description>
            <dc:creator>Joe Curia</dc:creator>
            <category>v5/v6 Modules/Add-Ons</category>
            <pubDate>Mon, 08 Nov 2010 01:27:20 -0600</pubDate>
        </item>
    </channel>
</rss>
