Topic: Delayed posts

I think a few people have asked for a feature whereby posts wouldn't appear until approved by a moderator.

juman mentioned it last year:
http://punbb.org/forums/viewtopic.php?id=3457

I don't want to get into a debate about the rights and wrongs of this. Suffice it to say that this might be appropriate under certain circumstances.

Rickard said that it might be included at some point. Any news on this? Or is there a mod that does the job?

Re: Delayed posts

I was considering it for 1.2, but I just didn't have time to implement it. The easiest way I can think of is just adding a column to the posts and topic tables that says whether a post is "approved" or not. You could then make an admin plugin that displays all posts and topics that haven't yet been approved. That part is easy. The time-consuming and difficult part is to deal with the rest of the forum. Every single query that interacts with the posts and topics tables will have to be updated to take into account the approval column.

"Programming is like sex: one mistake and you have to support it for the rest of your life."

3

Re: Delayed posts

I have a need for this. The way I was thinking of doing it was to create a new table which has all the fields necessary for a post. When a post is submitted by anyone other than a admin/mod the data will go to the new table rather than its normal destination. When the post is approved the data will simply be re-submitted as if it were a new post being made at that time. The approval will be taken care of by something similar to the moderators multi-delete screen. That probably sounds like a complicated way of doing it but it relies mostly on new code rather than altering existing code.

Re: Delayed posts

That's not a bad idea. It would involve a lot less editing. You would however have to create two new tables, one for posts and one for topics.

"Programming is like sex: one mistake and you have to support it for the rest of your life."

Re: Delayed posts

I'm not a programmer, but I thought up a hack that might not be too hard to implement:

Each forum visible to the public can only be posted to by its moderators.

Each of these has a parallel forum that can be posted to by the public, but is invisible to them. The post link in each visible forum actually leads to the parallel forum that is invisible to everyone except the moderators and admins. The moderators subscribe to these forums so they are notified of posts. They can then somehow transfer the approved posts from the invisible to the visible forums.


Is this what Paul is suggesting?

Re: Delayed posts

Pauls suggesting a similar idea

7

Re: Delayed posts

Sort of. What I was actually suggesting was this

1. Tables are created which are identical to the post and topics tables, they could be called something like posttemp, topicstemp.

2. When posting as anything other than an admin or mod the posts will actually end up in the temp tables rather than the posts and topics tables. This could be done either by modifying post.php or, even easier, by having a new file called post_temp.php. That way the only alterations to punbb code would be to the destination of the "Post reply" and "Post new topic" links.

3. An admin plugin something like the mods multi-delete form would be constructed to allow for post approval.

4. When posts are approved the posts and topics databases would be updated in exactly the same way as they would be in the case of new posts.

5. Notification would be via something similar to the notification of new reports.

Doing it this way involves almost no editing of existing code. There is also no increased overhead because the "active" tables don't need new columns and the database queries don't need any further conditions attached to deal with posts that haven't been approved. This is a close a method as I could think of to make post approval a bolt on extra rather than a complicated mod.