%META:TOPICINFO{author="DonnyKurniawan" date="1065259132" format="1.0" version="1.3"}%
---+ HiddenTextPlugin

This is a plugin that you can use to hide a block of text in the edit page, so that the text cannot be edited or changed unless the user has the access permission. The text is still rendered in the view page.

---++ Syntax Rules

	* %<nop>STARTHIDDEN% ... %<nop>ENDHIDDEN%
	* Text outside the %<nop>STARTHIDDEN% ... %<nop>ENDHIDDEN% is not hidden in the edit page, thus it can be edited like the normal way.
	* The access permission is controlled by the ALLOWTOPICHIDDEN preference variable. Only people listed in the ALLOWTOPICHIDDEN variable that can edit the hidden text. Obviously, the ALLOWTOPICHIDDEN variable must be set inside the %<nop>STARTHIDDEN% ... %<nop>ENDHIDDEN% so that a user who has write access (but not listed in the ALLOWTOPICHIDDEN) cannot change the variable.
	* Only one %<nop>STARTHIDDEN% ... %<nop>ENDHIDDEN% block in one topic.
	* We do not use any marker to tag the location of the %<nop>STARTHIDDEN% ... %<nop>ENDHIDDEN%, as a result of this hidden text block is always put at the top of the topic.

---++ Examples
<verbatim>
%STARTHIDDEN%

<!--
	* Restrict who can see/edit the hidden text
		* Set ALLOWTOPICHIDDEN = Main.JoeSomebody
-->

Hello World

%ENDHIDDEN%
</verbatim>


---++ <nop>%TOPIC% Global Settings

Plugin settings are stored as preferences variables. To reference a plugin setting write ==%<nop>&lt;plugin&gt;_&lt;setting&gt;%==, for example, ==%<nop>HIDDENTEXTPLUGIN_SHORTDESCRIPTION%==

	* One line description, shown in the %TWIKIWEB%.TextFormattingRules topic:
		* Set SHORTDESCRIPTION = Hide a block of text in the edit page

	* Debug plugin: (See output in =data/debug.txt=)
		* Set DEBUG = 0

---++ Plugin Installation Instructions

__Note:__ The following instructions are for the administrator who installs the plugin on the server where TWiki is running.

	* Download the ZIP file from the Plugin web (see below)
	* Unzip ==%TOPIC%.zip== in your twiki installation directory. Content:
	  | *File:* | *Description:* |
	  | ==data/TWiki/%TOPIC%.txt== | Plugin topic |
	  | ==data/TWiki/%TOPIC%.txt,v== | Plugin topic repository |
	  | ==lib/TWiki/Plugins/%TOPIC%.pm== | Plugin Perl module |
	* (Dakar) Visit =configure= in your TWiki installation, and enable the plugin in the {Plugins} section.

---++ Plugin Info

|  Plugin Author: | TWiki:Main/DonnyKurniawan |
|  Plugin Version: | 04 Oct 2003 (V1.001) |
|  Change History: | <!-- versions below in reverse order -->&nbsp; |
|  04 Oct 2003: | Change the syntax so that the hidden block can include '}%' |
|  03 Oct 2003: | Initial version |
|  CPAN Dependencies: | none |
|  Other Dependencies: | none |
|  Perl Version: | 5.005 |
|  Plugin Home: | http://TWiki.org/cgi-bin/view/Plugins/%TOPIC% |
|  Feedback: | http://TWiki.org/cgi-bin/view/Plugins/%TOPIC%Dev |

__Related Topics:__ %TWIKIWEB%.TWikiPreferences, %TWIKIWEB%.TWikiPlugins
 
-- %TWIKIWEB%.DonnyKurniawan - 03 Oct 2003

%META:FILEATTACHMENT{name="sample.mov" attr="h" comment="A small <nop>QuickTime movie" date="1060215181" path="sample.mov" size="494658" user="DonnyKurniawan" version="1.1"}%
