none
[openafs-wiki.git] / TWiki / TWikiSkins.mdwn
1 <div>
2   <ul>
3     <li><a href="#TWiki Skins"> TWiki Skins</a><ul>
4         <li><a href="#Overview"> Overview</a></li>
5         <li><a href="#Defining Skins"> Defining Skins</a></li>
6         <li><a href="#Activating Skins"> Activating Skins</a></li>
7       </ul>
8     </li>
9   </ul>
10 </div>
11
12 # <a name="TWiki Skins"></a> TWiki Skins
13
14 _Skins overlay regular templates with alternate header/footer layouts; topic text is not affected_
15
16 ## <a name="Overview"></a> Overview
17
18 Skins are customized [[TWikiTemplates]] files. You can use skins to change the look of a %WIKITOOLNAME% topic, for example, the layout of the header and footer. Rendered text between header and footer does **_not_** change. You can also use skins to define an alternate view, like a view optimized for printing.
19
20 ## <a name="Defining Skins"></a> Defining Skins
21
22 Skin files are located in the `twiki/templates` directory and are named with the syntax: <code>**&lt;scriptname&gt;.&lt;skin&gt;.tmpl**</code>. For example, the **Printable** skin for the `view` template is `view.print.tmpl`.
23
24 ## <a name="Activating Skins"></a> Activating Skins
25
26 A skin can be activated in two ways:
27
28 - Define the `SKIN` Preference variable in [[TWikiPreferences]], one of the [[WebPreferences]], or in a user - Main.admin - topic.
29   - `Set SKIN = print`
30
31 - Add `?skin=name` to the URL, for this example:
32   - <http://www.dementia.org/twiki//view/%WEB%/%TOPIC%?skin=print> (for the print view skin)
33   - <http://www.dementia.org/twiki//view/%WEB%/%TOPIC%?skin=plain> (for the plain view skin that has no header and footer)
34
35 The <code>**?skin=name**</code> URL parameter overrides the SKIN Preference value.
36
37 -- [[PeterThoeny]] - 14 Jul 2001 <br />