Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Re: rah_post_versions: Revision control for articles, forms and pages
I will look what can be done about the diff feature. I’ve already started doing it, just still needs the code that compares the changes. Hopefully I have the time to do it during next week (or this, or today who knows).
JanDW wrote:
Swell… thanks again. I guess I needed
setidinstead ofidthough. In case anybody else wants to use this:
Oh, yes. Sorry about that :-)
Last edited by Gocom (2010-06-10 05:40:29)
Offline
Re: rah_post_versions: Revision control for articles, forms and pages
No problem – keeps me on my toes. :-)
I’ve noticed that each revision has an ID that increments based on the total number of revisions.
Since I’m using this txp as a wiki I’m having a lot of revisions. In just a few days I think I’m up to 150. I’m a little worried this number might get to be unwieldly soon or even max out?
Is that a reasonable fear? If so, couldn’t the revision id’s be per setid?
Last edited by JanDW (2010-06-10 21:54:49)
TXPDream – A Textpattern Tag Library for Adobe Dreamweaver. (updated for 4.2.0) | jdw_if_ajax – Only serve certain parts of a page when requested with AJAX
Offline
Re: rah_post_versions: Revision control for articles, forms and pages
JanDW wrote:
Is that a reasonable fear?
I don’t know, is it? :-) I can say that the maximum value of INT is 4294967295. If you fear that it’s going run out, you can change the field type to BIGINT which can store values up to 18446744073709551615. If you end up changing the type, remember to chage the zerofill (padding) value to greater (or remove it) from the current 12.
Anyways, let’s say that every revision takes 2 KB of space. With 4294967295 revisions, you would have 8 terabytes of data stored. That’s a lot :-)
Last edited by Gocom (2010-06-11 00:07:27)
Offline
Re: rah_post_versions: Revision control for articles, forms and pages
Jukka,
Seriously mate – this is killer. Thank you!
:)
—
Tom
Offline
Re: rah_post_versions: Revision control for articles, forms and pages
Version 0.4 is out. It’s wild, and it likes to look revisions funny. I gave it markers. Results are colorful.

Red blocks for removed, greens for flower gardens.
Changelog:
- Added diff tool. The feature is found from the list view’s multiedit: check two revisions and select “Diff” from the drop-down. The diff feature uses Paul Butler’s Simple Diff Algorithm.
- Added Are you sure? checks to the multiedit.
renobird wrote:
Seriously mate – this is killer. Thank you!
Thanks Tom :-)
Offline
Re: rah_post_versions: Revision control for articles, forms and pages
In Diff tool when the first version of field didn’t contain anything it looks like i 2px line. Maybe it worth to add min-height to this blocks?

Last edited by the_ghost (2010-06-11 06:26:55)
Providing help in hacking ATM! Come to courses and don’t forget to bring us notebook and hammer! What for notebook? What a kind of hacker you are without notebok?
Offline
Re: rah_post_versions: Revision control for articles, forms and pages
Gocom wrote:
With 4294967295 revisions, you would have 8 terabytes of data stored.
I’ll get back to you then :)
Added diff tool.
Très cool!
TXPDream – A Textpattern Tag Library for Adobe Dreamweaver. (updated for 4.2.0) | jdw_if_ajax – Only serve certain parts of a page when requested with AJAX
Offline
Re: rah_post_versions: Revision control for articles, forms and pages
the_ghost wrote:
In Diff tool when the first version of field didn’t contain anything it looks like i 2px line. Maybe it worth to add
min-heightto this blocks?
Good idea, but it’s not possible to make it as high as the line. Every browser handles line height differently and block elements do not scale according dpi/zoom setting set for fonts.
From my point of view, basically it now looks as good as it would look with min-height. The height would never be same as the line-height. It’s as usable and it reserves important space.
Only viable method is to add unbreakable space inside the blocks, or remove the blocks altogether if the older is empty.
Offline
Re: rah_post_versions: Revision control for articles, forms and pages
OK, now this plugin officially spanks my butt and calls me Judy.
The only thing I could think of to make it better would be an accordion for contained revisions…
- Item 1 (+)
- Item 2 (-)
- Revision 1
- Revision 2
- Revision 3
- Item 3 (+)
+5 Finland. THANKS
Offline
Re: rah_post_versions: Revision control for articles, forms and pages
Minor version 0.5 released. Makes no difference to anything, just clean code a bit. Changelog:
- Removed twice presented conditional.
Offline
Re: rah_post_versions: Revision control for articles, forms and pages
I must say that this plugin is awesome and it is a great step forward for TXP itself! Filled a gap between other CMS. Thank so much!
Z-
Offline
Re: rah_post_versions: Revision control for articles, forms and pages
Hi,
I don’t tried your plugin yet, but it seems a great and very useful one.
Do you think that it will be possible to work with multiple environment (dev, testing, production) thank to it? Or maybe did you plan a feature like this?
Last edited by Grégocentrique (2010-06-16 16:03:35)
Offline
Re: rah_post_versions: Revision control for articles, forms and pages
Grégocentrique wrote:
I don’t tried your plugin yet, but it seems a great and very useful one.
I sure hope so :-)
Do you think that it will be possible to work with multiple environment (dev, testing, production) thank to it? Or maybe did you plan a feature like this?
Sorry, I’m not really following :-) Maybe I’m bit dummy and my eyes are transfering your question as mambo-jambo. Wouldn’t be the first nor the last time.
Are you asking if the plugin works in all production modes? Then yes. But I supose that wasn’t what you meant.
If you are asking if it allows you to run multiple enviroments of one install (site), then no. It’s a revision manager; it stores revisions and comes with a revision browser. That sort of development enviroment is not what the plugin is ment to do and is not planned.
If you are asking if saving revision could optinally turned off based on the production status, then why not. That can be implemented.
Offline
Re: rah_post_versions: Revision control for articles, forms and pages
Hello and thank you for this great concept and plug in.
I’m getting these errors when I click on the “event” = “write” and I click on one of the instances…
Notice: Array to string conversion in /home/myDir/public_html/mysite.com/textpattern/lib/txplib_misc.php(594) : eval()'d code on line 1110
Warning: htmlspecialchars() expects parameter 1 to be string, array given in /home/myDir/public_html/mysite.com/textpattern/lib/txplib_misc.php(594) : eval()'d code on line 1120
Anyone else getting this?
Thank you in advance.
TJ
“…freely ye have received, freely give.” | www.PublishingAWebsite.com
Offline
Re: rah_post_versions: Revision control for articles, forms and pages
TJ wrote:
Hello and thank you for this great concept and plug in.
Thanks you, TJ :-)
I’m getting these errors when I click on the “event” = “write” and I click on one of the instances…
What are you meaning exactly? What is the URL requested (/textpattern/?foo=bar) when that happens, or could take screenshot, so I could get a clearer look of what you’re meaning. I will be happy look at it as soon as I know where it happens.
Offline