[RFC] MediaWiki-like Diff Engine for Posts

Note: We are moving the topics of this forum and it will be deleted at some point

Publish your own request for comments/change or patches for the next version of phpBB. Discuss the contributions and proposals of others. Upcoming releases are 3.2/Rhea and 3.3.
Post Reply
dwieeb
Registered User
Posts: 6
Joined: Mon Mar 09, 2009 3:11 pm

[RFC] MediaWiki-like Diff Engine for Posts

Post by dwieeb »

Whew, big one, I know. That's why I put it in the 4.0 RFCs. I'm under the impression that 4.0 will be built from the ground up (or from a PHP framework on up), which will make implementing this RFC a tad easier, am I right?

Reasons: I'm a pretty firm believer that applications should keep all inputted data unless the user specifically requests that it be removed from the application entirely. I believe the best way to maintain all the post data in phpBB is by implementing a diff viewer much like MediaWiki's diff viewer for articles. I'm not entirely sure how MediaWiki does this, but it can't be too intensive on the database, can it? Plus, posts aren't edited or deleted that often. But when they are, a system like this will really help.

I think it would be advantageous for all administrators and moderators (and possibly members, but only for their own posts) to have the ability to review all revisions of all posts. This will serve many benefits:
  • Too many forums have an "archive" forum so that they can attempt to keep a history of troublesome or old topics. Wouldn't it be nice to check the deletion log and view the entire details of a deleted topic?
  • Keep staff members in check. Do your moderators ever edit or delete a post that you wish they hadn't? Wouldn't it be nice to revert to any previous revision of a post or bring it back from the dead? Wouldn't it be nice to see exactly what they edited or deleted?
  • Does a member ever come up to you with a question about an old topic that you wish you could answer?
  • Does a member ever accuse another member of posting something inappropriate, but the post in question was edited before the moderators could take a look at it?

DrStrangelove
Registered User
Posts: 13
Joined: Thu Jul 01, 2010 3:33 pm

Re: [RFC] MediaWiki-like Diff Engine for Posts

Post by DrStrangelove »

VBulletin has a feature like this and I can see the usefulness from a site staff standpoint. Not as useful as a recycle bin, but still useful.

Why didn't you suggest it for say 3.2? It doesn't have to be hard to implement.
You could store all the history in the post itself using special tags, and then you will only have to add a little bit of code to handle permissions and select which edits you want to view.

Nelsaidi
Registered User
Posts: 122
Joined: Tue Nov 11, 2008 5:44 pm

Re: [RFC] MediaWiki-like Diff Engine for Posts

Post by Nelsaidi »

Soft delete will be included in phpBB3.1 (which is basically delete a topic but its simply hidden, then a hard delete permisions to permanently remove it)

It does sound good and is useful, if automatically deleted after X days then database size increases could be managed.

DrStrangelove
Registered User
Posts: 13
Joined: Thu Jul 01, 2010 3:33 pm

Re: [RFC] MediaWiki-like Diff Engine for Posts

Post by DrStrangelove »

Err... OP was talking about a post-history feature. :)

Basically it means your post is stored as the last version + inverse diffs for each older version of the post. Makes the script logic simple. viewtopic just has to display the last version and can skip the rest in 99% of all cases. For the remaining 1% you just apply all the relevant diffs in order.

To answer OP. No, it isn't more database intensive if it is implemented right. It just uses more disc space to store the added history.

User avatar
imkingdavid
Registered User
Posts: 1050
Joined: Thu Jul 30, 2009 12:06 pm

Re: [RFC] MediaWiki-like Diff Engine for Posts

Post by imkingdavid »

A few of the points at the end of the OP hinted at this being used as a sort of trash bin type feature. As has been said, soft delete will be in 3.1, and this would be separate from that.

Anyway, I agree that post history/diff would be helpful for a few reasons, including accountability, and being able to revert changes if you for whatever reason don't like a new version. Also, moderators would be able to police things like edit wars, by being able to see what was changed to what and when and by whom and all that good stuff. And no one would be able to say "I never said that" unless they really didn't.
I do custom MODs. PM for a quote!
View My: MODs | Portfolio
Please do NOT contact for support via PM or email.
Remember, the enemy's gate is down.

User avatar
callumacrae
Former Team Member
Posts: 1046
Joined: Tue Apr 27, 2010 9:37 am
Location: England
Contact:

Re: [RFC] MediaWiki-like Diff Engine for Posts

Post by callumacrae »

Something like this, but with diff? http://www.phpbb.com/customise/db/mod/p ... revisions/

It'd be a fairly big patch, but I reckon this would be pretty useful (disabled by default) in 3.2.
Made by developers, for developers!
My blog

Post Reply