

http://your/twiki/bin/compare/Web/Topic?parameters from your browser
rev1=rev and rev2=rev render=interweave or render=sidebyside context=n skin=someskin compare.tmpl (or compare.skin.tmpl) for the side-by-side format,
and interweave.tmpl (or interweave.skin.tmpl) for the interwoven
format.
The templates itself are broken into 7 parts
template for start of page %REPEAT% template for unchanged section which is not printed according to context %REPEAT% template for unchanged section which is printed %REPEAT% template for changed section %REPEAT% template for added section %REPEAT% template for deleted section %REPEAT% template for end of pageAll empty templates for a section default to their predecessor. (E.g. if you do not specify a template for a deleted section, it defaults to the template for an added section, which in turn may default to the template for a changed section). In the templates for a section,
%TEXT1% is replaced by the text of the old revision
and %TEXT2% is replaced by the text of the new revision.
In interwoven output, only %TEXT1% is used.
Examples for templates can be found in the default template files from
the distribution (compare.tmpl, compare.pattern.tmpl, interweave.tmpl,
interweave.pattern.tmpl ).
twikiCompareAdd twikiCompareDelete twikiCompareChange1 twikiCompareChange2 twikiCompareAdd and twikiCompareChange1 are defined with
a light red background and stroken out text, and twikiCompareDelete
and twikiCompareChange2 are defined with a light green background.
CompareRevisionsAddOn.zip in your twiki installation directory. Content: | File: | Description: |
|---|---|
data/TWiki/CompareRevisionsAddOn.txt | Add-on topic |
bin/compare | Add-on script |
lib/TWiki/UI/Compare.pm | Perl package used by the script |
templates/compare.tmpl | Template for side-by-side output |
templates/compare.pattern.tmpl | Same for pattern skin |
templates/interweave.tmpl | Template for interwoven output |
templates/interweave.pattern.tmpl | Same for pattern skin |
lib/TWiki/Plugins/CompareRevisionsAddonPlugin.pm | Helper plugin |
data/TWiki/CompareRevisionsAddonPlugin.txt | Plugin topic |
pub/TWiki/CompareRevisionsAddOn/interweaved.png | Interwoven screenshot |
pub/TWiki/CompareRevisionsAddOn/sidebyside.png | Side-by-side screenshot |
data/Sandbox/CompareRevisionsAddOnDemoTopic.txt | Demonstration topic |
data/Sandbox/CompareRevisionsAddOnDemoTopic.txt,v | Demonstration topic history |
%SCRIPTURL%/compare/Web/Topic with some existing topic. (Try for instance CompareRevisionsAddOnDemoTopic and compare your output with above screenshots).
| Add-on Author: | TWiki:Main/JChristophFuchs |
| Add-on Version: | 07 Nov 2007 |
| Change History: | |
| 07 Nov 2007 | Arthur Clemens: Updated for TWiki 4.2 |
| 09 Apr 2006 | Updated for new PatternSkin in TWikiRelease04x00x02 |
| 26 Feb 2006 | Updated for TWiki 4 |
| 02 Mar 2005 | Corrected bug concerning uninitialized elements |
| 03 Feb 2005 | Removed blank paragraphs before comparing |
| 20 Jan 2005 | Initial version |
| CPAN Dependencies: | HTML::Parser, HTML::Tagset, HTML::Tree |
| Other Dependencies: | none |
| Perl Version: | 5.005 |
| License: | GPL |
| Add-on Home: | http://TWiki.org/cgi-bin/view/Plugins/CompareRevisionsAddOn |
| Feedback: | http://TWiki.org/cgi-bin/view/Plugins/CompareRevisionsAddOnDev |
| Appraisal: | http://TWiki.org/cgi-bin/view/Plugins/CompareRevisionsAddOnAppraisal |

| Copyright 2011 The Board of Trustees of the University of Illinois.webmaster@cs.uic.edu |
WISEST Helping Women Faculty Advance Funded by NSF | | |