Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.5 > vBulletin 3.5 Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Post Edit History Viewer Details »»
Post Edit History Viewer
Version: 1.00, by Lieva Lieva is offline
Developer Last Online: Mar 2008 Show Printable Version Email this Page

Version: 3.5.1 Rating:
Released: 01-21-2006 Last Update: 11-06-2006 Installs: 46
DB Changes Uses Plugins
Is in Beta Stage  
No support by the author.

When someone edits a post, the old message is stored in another table before the new one overwrites the old message.

Posts that have been edited will have "view edit history" displayed below the post count in the postbit.

Clicking "view edit history" allows previous versions of a post to be seen.

The postbit and postbit_legacy templates are altered using a similar method to the one used in the vbshout extension by Zero Tolerance, i.e. a search and replace. This means that no manual alterations to these templates are required.

Normally, everyone can see the post history for all the posts, however, the XML file post_hist_mods_only.xml restricts it to mods only (and the poster themselves). (Both versions should not be installed at the same time).

--------------------------------

Updated:

use post-hist_1_1b.zip

Changes

- Enable/Disable by forum
-- On/Off by forum

- Enable/Disable by usergroup
-- Can see own history: Yes/No
-- Can see everyone's history: Yes/No

- Indicates who made the edit (if it wasn't the original author)

- Workaround for unknown templates
-- Insert <<Insert Post History>> into postbit and postbit_legacy templates
-- (This is only for templates where the auto-match doesn't work)

The options are controlled by admincp.

By default, nobody can see any of the histories. At minimum, you should set the admin usergroup to see all histories.

Request

I don't know how 3.6.x products work, but if someone tries it on 3.6.x and it works, that would be good to know. I don't actually have 3.6 on our own forums, so can't test it.

Also, if you find out any bugs for < 3.6, that would be good to know too.

Install Info

The zip file contains:

bit_field_post_hist.xml -> XML for permissions
post_hist_1_1.xml -> product file

To install:

copy bit_field_post_hist.xml to /includes/xml

and install the product.

In theory, this should work as an upgrade to the previous version. However, I haven't tested that.

If you uninstall the old version and install the new version, you will lose any saved post histories.

Troubleshooting

bitfield cache
You might have to open:

yourserver.com/admincp/index.php?do=buildbitfields

This re-calculates the bitfields that have been altered. On some versions, the product installer will automatically do it.

Moderators
The postbits determine if a post is a person's own post by seeing if they have permission to edit the post. This means that if you give mods the rights to see their own post histories, then they will be able to click to see everyone elses post histories as they have the rights to edit all posts. However, the link won't have any effect as the actual viewer is restricted based on actual poster.

Usage

The XML file should add 2 options that can be set when setting up a usergroup and 1 new option for each forum.

New options for each usergroup:

Can See Post History (Yes/No)
---- Allows members of this usergroup to see all post histories

Can See Own Post History (Yes/No)
---- Allows members of this usergroup to see their own post history

New option for each forum:

Post History Displayed (Yes/No)
---- Shows post history for every post in this forum

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #112  
Old 06-25-2006, 09:20 AM
kafi kafi is offline
 
Join Date: Apr 2004
Posts: 379
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I checked the thread but from it seems that this feature will not be available in 3.6 so I guess it will take long time to wait for it frm vb.com.
Furthermore I guess that there might be more usefull option for this than vb.com will include in official release.
To me it can be used for common knowleadge base - aka wiki.
Reply With Quote
  #113  
Old 06-27-2006, 11:02 PM
Lieva Lieva is offline
 
Join Date: Apr 2005
Posts: 55
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Djamil
I doubt it since this is already under consideration for a standard feature and Lieva was not online for over a month. Feel free to support all people at vb.com that expressed their needs in the thread. :-)

For the meantime I maybe will post in one of the help forums here since it should be no big deal to make this available to mods only. Should be a simple template conditional which I don't know how to place into the XML-file - somebody should be able to help if I find the time to post a proper request.

Djamil
Glad to see it has been useful for some peeople. I did this for our own forum, so it's sorta hard coded to what I wanted but I thought it would be nice to share . It isn't actually that complex so adding the extra features would make it (somewhat) more complex. (There is also a slight problem in that I have somehow killed my local copy of vbulletin that I use for testing changes and haven't got around to figuring out how I broke it ).

Anyway, for those who are looking at the XML, there is mainly 2 parts:

The hookpoint: parse_templates

This is basically:

$insert_point = "blah";
$insert_point2 = "blah2";
$new_text = "new text";

Then a few commands do a search and replace on the templates. This is why there is no need to manually update the templates. The problem is that the required insert_point is different from version to version, that's why there is 2 insert_points.

Also, the text required here is the text of the template after some processing, rather than just copy/paste the template from admincp ... so hard to get it to match for different versions. It is also hard to read .

The check code is
( \$post['numedits'] != 0 ) && ( \$post['editlink'] )

This means that it displays the edit history options as long as there is more than 0 edits and the user is permitted to edit the post.

Any variables that are available to the postbit can be used. I am not sure if usergroup settings are available.

I think that replacing

( \$post['editlink'] )

with

( \$show['inlinemod'] )

in the XML before uploading should make it so only mods can see the controls for viewing older versions. (This assumes that you are using inline mods)

The 2nd hookpoint is
showthread_postbit_create

This is less complex. It is where the post is actually modified so that it looks at the old post. Also, it checks permissions. This is the only part that needs to be updated if you don't mind users seeing the edit history options as long as they can't use the options.

The check is:

( can_moderate($thread['forumid']) || ($post['userid'] == $vbulletin->userinfo['userid'] ) )

The 1st term is the one that allows moderators to view the post history and the second term is for the user themselves.

Changing it to:

( can_moderate($thread['forumid']) )

would mean that only moderators can use the feature.

So, making those 2 chances to the XML (just requires a text editor) should make it so that only mods can see/use the edit history system. I don't have a "scratch" version of 3.5.1 atm, so I can't confirm that.

Btw, have people tried this out on other 3.5.x versions? It would probably be worth a yes/no question for each version. Also, posting the default postbit (and postbit_legacy) for those versions would help if they aren't working.

Getting it to work for the other versions (if they don't work), should just be a matter of adding more $insert_pointx strings.

Also, I haven't actually looked, but is the 3.6.x plugin system compatible with 3.5.x or have they redone everything again ?
Reply With Quote
  #114  
Old 06-29-2006, 01:36 PM
Djamil Djamil is offline
 
Join Date: Mar 2006
Location: Germany
Posts: 28
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thank you very much for clarifying this, I will check if this will do it.

BTW, I have "post hist mods only.xml" installed on a 3.5.4 forum and it works as you have designed it. If I manage to change it to work only for mods with your info I will owe you one ... :-)

Djamil
Reply With Quote
  #115  
Old 06-29-2006, 02:06 PM
murdo murdo is offline
 
Join Date: Jun 2006
Location: Scotland, UK
Posts: 29
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great job, but I was wondering if there was any way to extend the information? (basically, i want to know who did the edit as well as view the history!)

Is this possible?
Reply With Quote
  #116  
Old 07-12-2006, 06:37 PM
kafi kafi is offline
 
Join Date: Apr 2004
Posts: 379
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Lieva please let us know wheter you are interested to continue development of this hack or do you agree to pick this up by somebody else.

I willing to pay for this hack!

Thank you
Reply With Quote
  #117  
Old 09-07-2006, 06:35 PM
SnickersTK SnickersTK is offline
 
Join Date: Apr 2005
Location: Denmark
Posts: 82
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Can anyone help fix this error

I have no idea what it means or how to fix it. It only appears when you go to thread's you've posted in or your pressing edit, it seems


please please please help
Reply With Quote
  #118  
Old 09-08-2006, 07:36 PM
SnickersTK SnickersTK is offline
 
Join Date: Apr 2005
Location: Denmark
Posts: 82
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

*waited 24 hours as the rules says*

anyone, please? I would really like this hack to work.
Reply With Quote
  #119  
Old 09-11-2006, 04:05 AM
SnickersTK SnickersTK is offline
 
Join Date: Apr 2005
Location: Denmark
Posts: 82
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

anyone *bumps again*
Reply With Quote
  #120  
Old 09-13-2006, 12:56 PM
Cybertims Cybertims is offline
 
Join Date: Nov 2005
Location: Bedfordshire
Posts: 203
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Can you please post the templates edits it would need since the plugin version doesnt work for me as the line it looks for isnt there anymore.....it has all ben changed.

Cheers.
Reply With Quote
  #121  
Old 09-19-2006, 04:33 AM
Protonus Protonus is offline
 
Join Date: Aug 2005
Location: Rochester, NY
Posts: 47
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ack it seems this broke in 3.6. Just went to use it on my board and the buttons don't show in the template anymore ugh. Anyone got an idea how to fix this in 3.6? I'm assuming this is what Cybertims was enquiring about.

This really ought to be a standard feature in vB... I can't see why you wouldn't want this and if anything you could turn it off...

Anyone have a link to the thread that was aforementioned for support of this as a feature in vB?
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 06:51 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05192 seconds
  • Memory Usage 2,322KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete