<li><a href="#TWiki Text Formatting"> TWiki Text Formatting</a><ul>
<li><a href="#TWiki Editing Shorthand"> TWiki Editing Shorthand</a></li>
<li><a href="#Using HTML"> Using HTML</a><ul>
- <li><a href="#HTML and TWiki Usability"> HTML and TWiki Usability</a></li>
- <li><a href="#TWiki HTML Rendering"> TWiki HTML Rendering</a></li>
- <li><a href="#TWiki and _JavaScript"> TWiki and JavaScript</a></li>
+ <li><a href="#Script tags"> Script tags</a></li>
</ul>
</li>
<li><a href="#Hyperlinks"> Hyperlinks</a><ul>
# <a name="TWiki Text Formatting"></a> TWiki Text Formatting
-Working in TWiki is as easy as typing in text - **exactly like email**. You don't need to know HTML, though you can use it if you prefer. Links to topics are created automatically when you enter [[WikiWords]]. And TWiki shorthand gives you all the power of HTML with a simple coding system that takes no time to learn. It's all laid out below - refer back to this page in a pop-up window from the **Edit** screen.
+Working in TWiki is as easy as typing in text. You don't need to know HTML, though you can use it if you prefer. Links to topics are created automatically when you enter [[WikiWords]]. And TWiki shorthand gives you all the power of HTML with a simple coding system that takes no time to learn. It's all laid out below.
<a name="TWikiShorthand"></a>
## <a name="TWiki Editing Shorthand"></a> TWiki Editing Shorthand
-<table bgcolor="#000000" border="1" cellpadding="3" cellspacing="1">
+<table bgcolor="#ffffff" border="1" cellpadding="3">
<tr bgcolor="#ffffff">
- <td><strong>Formatting Command:</strong></td>
- <td><strong>Example: You write:</strong></td>
- <td><strong>You get:</strong></td>
+ <th width="50%"> Formatting Command: </th>
+ <th width="25%"> You write: </th>
+ <th width="25%"> You get: </th>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Paragraphs:</strong> %BR% Blank lines will create new paragraphs. </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
+ <tr valign="top">
+ <td><strong>Paragraphs:</strong> %BR% Blank lines will create new paragraphs. </td>
+ <td><pre>
1st paragraph
2nd paragraph
-</pre> </font></span></td>
- <td valign="top"> 1st paragraph <p> 2nd paragraph </p>
+</pre></td>
+ <td> 1st paragraph <p> 2nd paragraph </p>
</td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Headings:</strong> %BR% At least three dashes at the beginning of a line, followed by plus signs and the heading text. One plus creates a level 1 heading (most important), two pluses a level 2 heading; the maximum is level 6. <strong><em>Note:</em></strong> A Table of Content can be created automatically with the <code>%TOC%</code> variable, see [[Main/TWikiVariables]]. Any heading text after <code>!!</code> is excluded from the TOC; for example, write <code>---+!! text</code> if you do not want to list a header in the TOC. </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
+ <tr valign="top">
+ <td><strong>Headings:</strong> %BR% Three or more dashes at the beginning of a line, followed by plus signs and the heading text. One plus creates a top level heading, two pluses a second level heading, etc. The maximum heading depth is 6. <p> You can create a table of contents with the [[Main/TWikiVariables#VarTOC]] variable. If you want to <strong>exclude</strong> a heading from the TOC, put <code>!!</code> after the <code>---+</code>. </p>
+ <p> %X% Empty headings are allowed, but won't appear in the table of contents. </p>
+ </td>
+ <td><pre>
---++ Sushi
-
---+++ Maguro
-</pre> </font></span></td>
- <td valign="top">
+---+++!! Not in TOC
+</pre></td>
+ <td>
<h2>Sushi</h2>
- <p>
- </p>
<h3>Maguro</h3>
+ <h3>Not in TOC</h3>
</td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Bold Text:</strong> %BR% Words get <strong>bold</strong> by enclosing them in <code>*</code> asterisks. </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
+ <tr valign="top">
+ <td><strong>Bold Text:</strong> %BR% Words get shown in <strong>bold</strong> by enclosing them in <code>*</code> asterisks. </td>
+ <td><pre>
*Bold*
-</pre> </font></span></td>
- <td valign="top"><strong>Bold</strong></td>
+</pre></td>
+ <td><strong>Bold</strong></td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Italic Text:</strong> %BR% Words get <em>italic</em> by enclosing them in <code>_</code> underscores. </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
+ <tr valign="top">
+ <td><strong>Italic Text:</strong> %BR% Words get shown in <em>italic</em> by enclosing them in <code>_</code> underscores. </td>
+ <td><pre>
_Italic_
-</pre> </font></span></td>
- <td valign="top"><em>Italic</em></td>
+</pre></td>
+ <td><em>Italic</em></td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Bold Italic:</strong> %BR% Words get <em>_bold italic</em> by enclosing them in <code>_</code> double-underscores. </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
+ <tr valign="top">
+ <td><strong>Bold Italic:</strong> %BR% Words get shown in <strong><em>bold italic</em></strong> by enclosing them in <code>__</code> double-underscores. </td>
+ <td><pre>
__Bold italic__
-</pre> </font></span></td>
- <td valign="top"><strong><em>Bold italic</em></strong></td>
+</pre></td>
+ <td><strong><em>Bold italic</em></strong></td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Fixed Font:</strong> %BR% Words get shown in <code>fixed font</code> by enclosing them in <code>=</code> equal signs. </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
+ <tr valign="top">
+ <td><strong>Fixed Font:</strong> %BR% Words get shown in <code>fixed font</code> by enclosing them in <code>=</code> equal signs. </td>
+ <td><pre>
=Fixed font=
-</pre> </font></span></td>
- <td valign="top"><code>Fixed font</code><p>
+</pre></td>
+ <td><code>Fixed font</code><p>
</p>
</td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Bold Fixed Font:</strong> %BR% Words get shown in <code><b>bold fixed font</b></code> by enclosing them in <code><b></b></code> double equal signs. </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
+ <tr valign="top">
+ <td><strong>Bold Fixed Font:</strong> %BR% Words get shown in <code><b>bold fixed font</b></code> by enclosing them in <code><b></b></code> double equal signs. </td>
+ <td><pre>
==Bold fixed==
-</pre> </font></span></td>
- <td valign="top"><code><b>Bold fixed</b></code></td>
+</pre></td>
+ <td><code><b>Bold fixed</b></code></td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong><em>Note:</em></strong> Make sure there is no space between the text and the bold, italic, or other indicators (<code>* _ __ = ==</code>). </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
+ <tr valign="top">
+ <td> %T% You can follow the closing bold, italic, or other (<code>* _ __ = ==</code>) indicator with normal punctuation, such as commas and full stops. <p> %X% Make sure there is no space between the text and the indicators. </p>
+ </td>
+ <td><pre>
_This works_,
-_this not _
-</pre> </font></span></td>
- <td valign="top"><em>This works</em>,%BR% _this not _ </td>
+_this does not _
+</pre></td>
+ <td><em>This works</em>,%BR% _this does not _ </td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Verbatim Mode:</strong> %BR% Surround code excerpts and other formatted text with <code><verbatim></code> and <code></verbatim></code> tags. %BR% <strong><em>Note:</em></strong> Use <code><pre></code> and <code></pre></code> tags instead if you want that HTML code is interpreted. %BR% <strong><em>Note:</em></strong> Each tag must be on a line by itself. </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
+ <tr valign="top">
+ <td><strong>Verbatim (Literal) Text:</strong> %BR% Surround code excerpts and other formatted text with <code><verbatim></code> and <code></verbatim></code> tags.%BR% %T% <code>verbatim</code> tags disable HTML code. Use <code><pre></code> and <code></pre></code> tags instead if you want the HTML code within the tags to be interpreted.%BR% <strong><em>%X% NOTE:</em></strong> Preferences variables (* Set NAME = value) are set within verbatim tags. </td>
+ <td><pre>
<verbatim>
class CatAnimal {
void purr() {
- <code here>
+ <code here>
}
}
</verbatim>
-</pre> </font></span></td>
- <td valign="top"><pre>
+</pre></td>
+ <td><pre>
class CatAnimal {
void purr() {
<code here>
}
</pre></td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Separator:</strong> %BR% At least three dashes at the beginning of a line. </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
+ <tr valign="top">
+ <td><strong>Separator (Horizontal Rule):</strong> %BR% Three or more three dashes at the beginning of a line.. </td>
+ <td><pre>
-------
-</pre> </font></span></td>
- <td valign="top">
+</pre></td>
+ <td>
<hr />
</td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>List Item:</strong> %BR% Three spaces, an asterisk, and another space. </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
- * bullet item
-</pre> </font></span></td>
- <td valign="top">
- <ul>
- <li> bullet item </li>
- </ul>
- </td>
- </tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Nested List Item:</strong> %BR% Six, nine, ... spaces, an asterisk, and another space. </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
- * level 1
- * level 2
-</pre> </font></span></td>
- <td valign="top">
+ <tr valign="top">
+ <td><strong>Bulleted List:</strong> %BR% Multiple of three spaces, an asterisk, and another space.%BR% %H% For all the list types, you can break a list item over several lines by indenting lines after the first one by <strong>at least 3 spaces</strong>. </td>
+ <td><pre>
+ * level 1
+ * level 2
+ * back on 1
+ * A bullet
+ broken over
+ three lines
+ * last bullet
+</pre></td>
+ <td>
<ul>
<li> level 1 <ul>
<li> level 2 </li>
</ul>
</li>
+ <li> back on 1 </li>
+ <li> A bullet broken over three lines </li>
+ <li> last bullet </li>
</ul>
</td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Ordered List:</strong> %BR% Three spaces, a number, a dot, and another space. Several types are available besides a number: <table border="1" cellpadding="0" cellspacing="0">
+ <tr valign="top">
+ <td><strong>Numbered List:</strong> %BR% Multiple of three spaces, a type character, a dot, and another space. Several types are available besides a number: <table border="1" cellpadding="0" cellspacing="0" style="border-width: 1px">
<tr>
- <th bgcolor="#99CCCC"><strong> Type </strong></th>
- <th bgcolor="#99CCCC"><strong> Generated Style </strong></th>
- <th bgcolor="#99CCCC"><strong> Sample Sequence </strong></th>
+ <th bgcolor="#6b7f93" maxcols="0" style=""><a href="http://localhost?sortcol=0;table=1;up=0#sorted_table" rel="nofollow" title="Sort by this column"><font color="#ffffff">Type</font></a></th>
+ <th bgcolor="#6b7f93" maxcols="0" style=""><a href="http://localhost?sortcol=1;table=1;up=0#sorted_table" rel="nofollow" title="Sort by this column"><font color="#ffffff">Generated Style</font></a></th>
+ <th bgcolor="#6b7f93" maxcols="0" style=""><a href="http://localhost?sortcol=2;table=1;up=0#sorted_table" rel="nofollow" title="Sort by this column"><font color="#ffffff">Sample Sequence</font></a></th>
</tr>
<tr>
- <td> 1. </td>
- <td> Arabic numerals </td>
- <td> 1, 2, 3, 4... </td>
+ <td bgcolor="#ecf2f8" style=""> 1. </td>
+ <td bgcolor="#ecf2f8" style=""> Arabic numerals </td>
+ <td bgcolor="#ecf2f8" style=""> 1, 2, 3, 4... </td>
</tr>
<tr>
- <td> A. </td>
- <td> Uppercase letters </td>
- <td> A, B, C, D... </td>
+ <td bgcolor="#ffffff" style=""> A. </td>
+ <td bgcolor="#ffffff" style=""> Uppercase letters </td>
+ <td bgcolor="#ffffff" style=""> A, B, C, D... </td>
</tr>
<tr>
- <td> a. </td>
- <td> Lowercase letters </td>
- <td> a, b, c, d... </td>
+ <td bgcolor="#ecf2f8" style=""> a. </td>
+ <td bgcolor="#ecf2f8" style=""> Lowercase letters </td>
+ <td bgcolor="#ecf2f8" style=""> a, b, c, d... </td>
</tr>
<tr>
- <td> I. </td>
- <td> Uppercase Roman Numerals </td>
- <td> I, II, III, IV... </td>
+ <td bgcolor="#ffffff" style=""> I. </td>
+ <td bgcolor="#ffffff" style=""> Uppercase Roman Numerals </td>
+ <td bgcolor="#ffffff" style=""> I, II, III, IV... </td>
</tr>
<tr>
- <td> i. </td>
- <td> Lowercase Roman Numerals </td>
- <td> i, ii, iii, iv... </td>
+ <td bgcolor="#ecf2f8" style=""> i. </td>
+ <td bgcolor="#ecf2f8" style=""> Lowercase Roman Numerals </td>
+ <td bgcolor="#ecf2f8" style=""> i, ii, iii, iv... </td>
</tr>
</table>
- <p>
- </p>
</td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
- 1. Sushi
- 1. Dim Sum
-
- A. Sushi
- A. Dim Sum
-
- i. Sushi
- i. Dim Sum
-</pre> </font></span></td>
- <td valign="top">
+ <td><pre>
+ 1. Sushi
+ 1. Dim Sum
+ 1. Fondue
+
+ A. Sushi
+ A. Dim Sum
+ A. Fondue
+
+ i. Sushi
+ i. Dim Sum
+ i. Fondue
+</pre></td>
+ <td>
<ol>
<li> Sushi </li>
<li> Dim Sum </li>
+ <li> Fondue </li>
</ol>
<p>
</p>
<ol>
<li type="A"> Sushi </li>
<li type="A"> Dim Sum </li>
+ <li type="A"> Fondue </li>
</ol>
<p>
</p>
<ol>
<li type="i"> Sushi </li>
<li type="i"> Dim Sum </li>
+ <li type="i"> Fondue </li>
</ol>
</td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Definition List:</strong> %BR% Three spaces, a dollar sign, the term, a colon, a space, followed by the definition. </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
- $ Sushi: Japan
- $ Dim Sum: S.F.
-</pre> </font></span></td>
- <td valign="top">
+ <tr valign="top">
+ <td><strong>Definition List:</strong> %BR% Three spaces, a dollar sign, the term, a colon, a space, followed by the definition. </td>
+ <td><pre>
+ $ Sushi: Japan
+ $ Dim Sum: S.F.
+</pre></td>
+ <td>
<dl>
<dt> Sushi </dt>
<dd> Japan </dd>
</dl>
</td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Table:</strong> %BR% Any number of lines of text. Each line is one row of the table consisting of one or more cells. Each cell starts and ends with a vertical bar '|'. Any spaces at the beginning of a line are ignored.%BR% <strong><em>Notes:</em></strong> %BB% <code>| *bold* |</code> cells are displayed as table headers.%BB% <code>| center-spaced |</code> cells are displayed center aligned.%BB% <code>| right-spaced |</code> cells are displayed right aligned.%BB% <code>| 2 colspan ||</code> cells are displayed as multi-span columns (i.e., a cell with no text spans a column).%BB% <code>|^|</code> cells with a caret indicate follow-up rows of multi-span rows (this functionality is provided by [[Main/TablePlugin]]).%BB% If a row contains a large amount of text, and you want it to be more readable while editing the table, split the row into multiple text lines by ending each line with a backslash character <code>'\'</code>.%BB% Table cells wrap automatically as determined by the browser. </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
+ <tr valign="top">
+ <td><strong>Table:</strong> %BR% Each row of the table is a line containing of one or more cells. Each cell starts and ends with a vertical bar '|'. Any spaces at the beginning of a line are ignored. <ul>
+ <li><code>| *bold* |</code> header cell with text in asterisks </li>
+ <li><code>| center-aligned |</code> cell with at least two, and equal number of spaces on either side </li>
+ <li><code>| right-aligned |</code> cell with more spaces on the left </li>
+ <li><code>| 2 colspan ||</code> and multi-span columns with multiple <tt>|</tt>'s right next to each other </li>
+ <li><code>|^|</code> cell with caret indicating follow-up row of multi-span rows </li>
+ <li> You can split rows over multiple lines by putting a backslash <code>'\'</code> at the end of each line </li>
+ <li> Contents of table cells wrap automatically as determined by the browser </li>
+ </ul> %T% The [[TWiki/TablePlugin]] provides the <code>|^|</code> multiple-span row functionality and additional rendering features </td>
+ <td><pre>
| *L* | *C* | *R* |
-| A2 | 2 | 2 |
-| A3 | 3 | 3 |
+| A2 | B2 | C2 |
+| A3 | B3 | C3 |
| multi span |||
-| A4-6 | four | four |
-|^| five | five |
-
+| A5-7 | 5 | 5 |
|^| six | six |
-</pre> </font></span></td>
- <td valign="top">
- <table border="1" cellpadding="0" cellspacing="0">
+|^| seven | seven |
+| split\
+ | over\
+ | 3 lines |
+| A9 | B9 | C9 |
+</pre></td>
+ <td>
+ <table border="1" cellpadding="0" cellspacing="0" style="border-width: 1px">
+ <tr>
+ <th bgcolor="#6b7f93" maxcols="0" style=""><a href="http://localhost?sortcol=0;table=2;up=0#sorted_table" rel="nofollow" title="Sort by this column"><font color="#ffffff">L</font></a></th>
+ <th bgcolor="#6b7f93" maxcols="0" style=""><a href="http://localhost?sortcol=1;table=2;up=0#sorted_table" rel="nofollow" title="Sort by this column"><font color="#ffffff">C</font></a></th>
+ <th bgcolor="#6b7f93" maxcols="0" style=""><a href="http://localhost?sortcol=2;table=2;up=0#sorted_table" rel="nofollow" title="Sort by this column"><font color="#ffffff">R</font></a></th>
+ </tr>
+ <tr>
+ <td bgcolor="#ecf2f8" style=""> A2 </td>
+ <td align="center" bgcolor="#ecf2f8" style=""> B2 </td>
+ <td align="right" bgcolor="#ecf2f8" style=""> C2 </td>
+ </tr>
<tr>
- <th bgcolor="#99CCCC"><strong> L </strong></th>
- <th bgcolor="#99CCCC"><strong> C </strong></th>
- <th bgcolor="#99CCCC"><strong> R </strong></th>
+ <td bgcolor="#ffffff" style=""> A3 </td>
+ <td align="center" bgcolor="#ffffff" style=""> B3 </td>
+ <td align="right" bgcolor="#ffffff" style=""> C3 </td>
</tr>
<tr>
- <td> A2 </td>
- <td align="center"> 2 </td>
- <td align="right"> 2 </td>
+ <td bgcolor="#ecf2f8" colspan="3" style=""> multi span </td>
</tr>
<tr>
- <td> A3 </td>
- <td align="center"> 3 </td>
- <td align="right"> 3 </td>
+ <td bgcolor="#ffffff" rowspan="3" style=""> A5-7 </td>
+ <td align="center" bgcolor="#ffffff" style=""> 5 </td>
+ <td align="right" bgcolor="#ffffff" style=""> 5 </td>
</tr>
<tr>
- <td colspan="3"> multi span </td>
+ <td bgcolor="#ecf2f8" style=""> six </td>
+ <td bgcolor="#ecf2f8" style=""> six </td>
</tr>
<tr>
- <td> A4-6 </td>
- <td> four </td>
- <td> four </td>
+ <td bgcolor="#ffffff" style=""> seven </td>
+ <td bgcolor="#ffffff" style=""> seven </td>
</tr>
<tr>
- <td> ^ </td>
- <td> five </td>
- <td> five </td>
+ <td bgcolor="#ecf2f8" style=""> split </td>
+ <td bgcolor="#ecf2f8" style=""> over </td>
+ <td bgcolor="#ecf2f8" style=""> 3 lines </td>
</tr>
<tr>
- <td> ^ </td>
- <td> six </td>
- <td> six </td>
+ <td bgcolor="#ffffff" style=""> A9 </td>
+ <td align="center" bgcolor="#ffffff" style=""> B9 </td>
+ <td align="right" bgcolor="#ffffff" style=""> C9 </td>
</tr>
</table>
</td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>WikiWord Links:</strong> %BR% CapitalizedWordsStuckTogether (or [[Main/WikiWords]]) will produce a link automatically. %BR% <strong><em>Note:</em></strong> In case you want to link to a topic in a different %WIKITOOLNAME% web write <code>Otherweb.TopicName</code>. (The link label is the the name of the web in case the is WebHome, else it is the topic name) </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
-WebNotify
+ <tr valign="top">
+ <td><strong>WikiWord Links:</strong> %BR% CapitalizedWordsStuckTogether (or [[Main/WikiWords]]) will produce a link automatically if preceded by whitespace or parenthesis. %BR% %T% If you want to link to a topic in a different web write <code>Otherweb.TopicName</code>. %BR% %H% The link label excludes the name of the web, e.g. only the topic name is shown. As an exception, the name of the web is shown for the WebHome topic. <p> It's generally a good idea to use the [[Main/TWikiVariables]] %TWIKIWEB% and %MAINWEB% instead of TWiki and Main. </p>
+ </td>
+ <td><pre>
+WebStatistics
+
+Sandbox.WebNotify
-Main.TWikiUsers
-</pre> </font></span></td>
- <td valign="top">[[Main/WebNotify]]<p>[[Main/TWikiUsers]]</p>
+Sandbox.WebHome
+</pre></td>
+ <td>[[Main/WebStatistics]]<p>[[Sandbox/WebNotify]]</p>
+ <p>[[Sandbox/WebHome]]</p>
</td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><a name="SquareBrackets"></a> <strong>Forced Links:</strong> %BR% You can create a forced internal link by enclosing words in double square brackets. %BR% <strong><em>Note:</em></strong> Text within the brackets may contain optional spaces; the topic name is formed by capitalizing the initial letter and by removing the spaces; for example, <code>[[text formatting FAQ]]</code> links to topic [[Main/TextFormattingFAQ]]. You can also refer to a different web and use anchors. %BR% <strong><em>Note:</em></strong> To "escape" double square brackets that would otherwise be a correct link, prefix the leading left square brackets with an exclamation point, that is, begin with <code>![[....</code></td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
+ <tr valign="top">
+ <td><strong>Anchors:</strong> %BR% You can define a reference inside a TWiki topic (called an anchor name) and link to that. To <strong><em>define</em></strong> an anchor write <code>#AnchorName</code> at the beginning of a line. The anchor name must be a [[Main/WikiWord]]. To <strong><em>link to</em></strong> an anchor name use the <code>[[MyTopic#MyAnchor]]</code> syntax. You can omit the topic name if you want to link within the same topic. </td>
+ <td><pre>
+[[WikiWord#NotThere]]
+
+[[#MyAnchor][Jump]]
+
+#MyAnchor To here
+</pre></td>
+ <td>[[Main/WikiWord#NotThere]]<p>[[Main/WebHome#MyAnchor]]</p>
+ <p><a name="MyAnchor"></a> To here </p>
+ </td>
+ </tr>
+ <tr valign="top">
+ <td><a name="HeRe"></a> <strong>Forced Links:</strong> %BR% You can create a forced internal link by enclosing words in double square brackets. %BR% Text within the brackets may contain optional spaces; the topic name is formed by capitalizing the initial letter and by removing the spaces; for example, <code>[[text formatting FAQ]]</code> links to topic [[Main/TextFormattingFAQ]]. You can also refer to a different web and use anchors. %BR% %T% To "escape" double square brackets that would otherwise make a link, prefix the leading left square bracket with an exclamation point. </td>
+ <td><pre>
[[wiki syntax]]
[[Main.TWiki users]]
escaped:
![[wiki syntax]]
-</pre> </font></span></td>
- <td valign="top">[[Main/WikiSyntax]]<p>[[Main/TWikiUsers]]</p>
+</pre></td>
+ <td>[[Main/WikiSyntax]]<p>[[Main/TWikiUsers]]</p>
<p> escaped: [[wiki syntax]] </p>
</td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Specific Links:</strong> %BR% Create a link where you can specify the link text and the link reference separately, using nested square brackets like <code>[[reference][text]]</code>. Internal link references (e.g. [[Main/WikiSyntax]]) and external link references (e.g. <a href="http://TWiki.org/" target="_top">http://TWiki.org/</a>) are supported. %BR% <strong><em>Note:</em></strong> The same <strong><em>Forced Links</em></strong> rules apply for internal link references. %BR% <strong><em>Note:</em></strong> For external link references, you can simply use a space instead of <code>][</code> to separate the link URL from the descriptive text. %BR% <strong><em>Note:</em></strong> Anchor names can be added as well, like <code>[[WebHome#MyAnchor][go home]]</code> and <code>[[http://gnu.org/#Action][GNU Action]]</code>. </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
-[[WikiSyntax][syntax]]
+ <tr valign="top">
+ <td><strong>Specific Links:</strong> %BR% You can create a link where you specify the link text and the URL separately using nested square brackets <code>[[reference][text]]</code>. Internal link references (e.g. [[Main/WikiSyntax]]) and URLs (e.g. <a href="http://TWiki.org/" target="_top">http://TWiki.org/</a>) are both supported. The rules described under <strong><em>Forced Links</em></strong> apply for internal link references. %BR% %T% Anchor names can be added as well, to create a link to a specific place in a topic. </td>
+ <td><pre>
+[[WikiSyntax][wiki syntax]]
[[http://gnu.org][GNU]]
-
-[[http://xml.org XML]]
-</pre> </font></span></td>
- <td valign="top">[[Main/WikiSyntax]]<p><a href="http://gnu.org" target="_top">GNU</a></p>
- <p><a href="http://xml.org" target="_top">XML</a></p>
- </td>
- </tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Anchors:</strong> %BR% You can define a link reference inside a %WIKITOOLNAME% topic (called an anchor name) and link to that. To <strong><em>define</em></strong> an anchor write <code>#AnchorName</code> at the beginning of a line. The anchor name must be a [[Main/WikiWord]]. To <strong><em>link to</em></strong> an anchor name use the <code>[[MyTopic#MyAnchor]]</code> syntax. You can omit the topic name if you want to link within the same topic. </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
-[[WikiWord#NotThere]]
-
-[[#MyAnchor][Jump]]
-
-#MyAnchor To here
-</pre> </font></span></td>
- <td valign="top">[[Main/WikiWord#NotThere]]<p>[[Main/WebHome#MyAnchor]]</p>
- <p><a name="MyAnchor"></a> To here </p>
+</pre></td>
+ <td>[[Main/WikiSyntax]]<p><a href="http://gnu.org" target="_top">GNU</a></p>
</td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Prevent a Link:</strong> %BR% Prevent a [[Main/WikiWord]] from being linked by prepending it with an exclamation point. </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
+ <tr valign="top">
+ <td><strong>Prevent a Link:</strong> %BR% Prevent a [[Main/WikiWord]] from being linked by prepending it with an exclamation point. </td>
+ <td><pre>
!SunOS
-</pre> </font></span></td>
- <td valign="top"> SunOS </td>
+</pre></td>
+ <td> SunOS </td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Disable Links:</strong> %BR% You can disable automatic linking of [[Main/WikiWords]] by surrounding text with <code><noautolink></code> and <code></noautolink></code> tags. %BR% <strong><em>Note:</em></strong> Each tag must be on a line by itself. %BR% <strong><em>Note:</em></strong> This also works for TWiki tables, but only if you add a blank line between the end of the table and the closing <code></noautolink></code> tag (known issue of the [[Main/TablePlugin]]). </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
+ <tr valign="top">
+ <td><strong>Disable Links:</strong> %BR% You can disable automatic linking of [[Main/WikiWords]] by surrounding text with <code><noautolink></code> and <code></noautolink></code> tags.%BR% %H% It is possible to turn off all auto-linking with a NOAUTOLINK preferences setting. </td>
+ <td><pre>
<noautolink>
RedHat &
SuSE
</noautolink>
-</pre> </font></span></td>
- <td valign="top"> RedHat & SuSE </td>
+</pre></td>
+ <td> RedHat & SuSE </td>
</tr>
- <tr bgcolor="#ffffff">
- <td valign="top"><strong>Mailto: Links:</strong> %BR% To create 'mailto:' links that have more descriptive link text, specify subject lines or message bodies, or omit the email address, you can write <code>[[mailto:user@domain descriptive text]]</code>. </td>
- <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre>
-[[mailto:a@z.com Mail]]
+ <tr valign="top">
+ <td><strong>Mailto Links:</strong> %BR% E-mail addresses are linked automatically. To create e-mail links that have more descriptive link text, specify subject lines or message bodies, or omit the e-mail address, you can write <code>[[mailto:user@domain][descriptive text]]</code>. </td>
+ <td><pre>
+a@b.com
+
+[[mailto:a@b.com]\
+[Mail]]
-[[mailto:?subject=Hi Hi]]
-</pre> </font></span></td>
- <td valign="top"><a href="mailto:a@z.com">Mail</a><p><a href="mailto:?subject=Hi">Hi</a></p>
+[[mailto:?subject=\
+Hi][Hi]]
+</pre></td>
+ <td><a href="mailto:a@b.com">a@b.com</a><p><a href="mailto:a@b.com">Mail</a></p>
+ <p><a href="mailto:?subject=Hi">Hi</a></p>
</td>
</tr>
</table>
## <a name="Using HTML"></a> Using HTML
-You can use just about any HTML tag without a problem - however, there are a few usability and technical considerations to keep in mind.
+You can use just about any HTML tag without a problem. You can add HTML if there is no TWiki equivalent, for example, write `<strike>deleted text</strike>` to get <strike>deleted text</strike>.
-### <a name="HTML and TWiki Usability"></a> HTML and TWiki Usability
+%X% There are a few usability and technical considerations to keep in mind:
-- %T% **TIP:** On collaboration pages, it's preferable NOT to use HTML, and to use [[TWiki shorthand|Main/WebHome#TWikiShorthand]] instead - this keeps the text uncluttered and easy to edit.
-- %X% **NOTE:** TWiki is designed to work with a wide range of browsers and computer platforms, holding to HTML 4.0 and XHTML 1.0 compatibility in the standard installation - adding raw HTML, particularly browser-specific tags (or any other mark-up that doesn't degrade well) will reduce compatibility.
-- Recommondations when using HTML:
- - Use [XHTML 1.0 Transitional](http://www.w3.org/TR/xhtml1/) syntax
- - Do not span a tag over more then one line
- - Remove all empty lines. TWiki inserts `<p />` paragraph tags on empty lines, which causes problems if done between tags that do not allow paragraph tags, like for example between table tags.
+- On collaboration pages, it's better **not** to use HTML, but to use [[TWiki shorthand|Main/WebHome#TWikiShorthand]] instead - this keeps the text uncluttered and easy to edit.
+- If you use HTML use [XHTML 1.0 Transitional](http://www.w3.org/TR/xhtml1/) syntax.
+- %X% Script tags may be filtered out, at the discretion of your TWiki administrator.
-### <a name="TWiki HTML Rendering"></a> TWiki HTML Rendering
+Recommendations when pasting HTML from other sources:
-- TWiki converts shorthand notation to XHTML 1.0 for display. To copy a fully marked-up page, simply view source in your browser and save the contents.
- - %T% If you need to save HTML frequently, you may want to check out TWiki:Plugins/GenHTMLAddon - it will "generate a directory containing rendered versions of a set of TWiki pages together with any attached files."
-- %X% **NOTE:** The opening and closing angle brackets - <code>**<...>**</code> - of an HTML tag **_must be on the same line_**, or the tag will be broken.
- - This feature allows you to enter an unclosed angle bracket - as a greater than or less than symbol - and have it automatically rendered as if you had entered its HTML character, `<`, ex: <code>**a < b**</code>
- - %T% If you're pasting in preformatted HTML text and notice problems, check the file in a text processor with no text wrap. Also, save without hard line breaks on text wrap, in your HTML editing program.
+- Copy only text between `<body>` and `</body>` tags.
+- Remove all empty lines. TWiki inserts `<p />` paragraph tags on empty lines, which causes problems if done between HTML tags that do not allow paragraph tags, like for example between table tags.
+- Remove leading spaces. TWiki might interpret some text as lists.
+- Do not span a tag over more than one line. TWiki requires that the opening and closing angle brackets - <code>**<...>**</code> - of an HTML tag are on the same line, or the tag will be broken.
+- In your HTML editing program, save without hard line breaks on text wrap.
-### <a name="TWiki and _JavaScript"></a> TWiki and JavaScript
+%T% TWiki converts shorthand notation to HTML for display. To copy a fully marked-up page, simply view the source in your browser and save the contents. If you need to save HTML frequently, you may want to check out TWiki:Plugins/PublishAddOn.
-You can use JavaScript for your TWiki applications. Since TWiki rendering might interfere with JavaScript code you need to escape it with HTML comments and `<pre>` tags:
+### <a name="Script tags"></a> Script tags
- <script type="text/javascript">
- <!-- Hide JavaScript and <pre> escape TWiki rendering
- ... put your JavaScript code here...
- // Stop hiding and stop </pre> escaping TWiki rendering -->
- </script>
+You can use HTML `<script>` tags for your TWiki applications. However note that your TWiki administrator can disable `<script>` in topics, and may have chosen to do so for security considerations. TWiki markup and [[TWikiVariables]] are **not** expanded inside script tags.
## <a name="Hyperlinks"></a> Hyperlinks
-Being able to create links without any formatting required is a core TWiki feature, made possible with [[WikiWords]]. New TWiki linking rules are a simple extension of the syntax that provide a new set of flexible options.
+Being able to create links without any special formatting is a core TWiki feature, made possible with [[WikiWords]] and inline URLs.
### <a name="Internal Links"></a> Internal Links
-- [[GoodStyle]] is a [[WikiWord]] that links to the GoodStyle topic located in the current %WIKITOOLNAME% web.
+- [[GoodStyle]] is a [[WikiWord]] that links to the GoodStyle topic located in the current web.
- [[NotExistingYet]] is a topic waiting to be written. Create the topic by clicking on the **?**. (Try clicking, but then, **Cancel** - creating the topic would wreck this example!)
- `http://...`, `https://...`, `ftp://...`, `gopher://...`, `news://...`, `file://...`, `telnet://...` and `mailto:...@...` are linked automatically.
-- Email addresses like `name@domain.com` are linked automatically.
+- E-mail addresses like `name@domain.com` are linked automatically.
- `[[Square bracket rules]]` let you easily create [[non-WikiWord links|Main/WebHome#SquareBrackets]].
- You can also write `[[http://yahoo.com Yahoo home page]]` as an easier way of doing external links with descriptive text for the link, such as [Yahoo home page](http://yahoo.com/).
## <a name="TWiki Variables"></a> TWiki Variables
-Variables are names that are enclosed in percent signs `%` that are expanded on the fly.
+TWiki Variables are names that are enclosed in percent signs `%` that are expanded on the fly.
- `%TOC%` : Automatically generates a table of contents based on headings in a topic - see the top of this page for an example.
- `%ATTACHURL%` : The attachment URL of the current topic. Example usage: If you attach a file to a topic you can refer to it as <code>**%ATTACHURL%/image.gif**</code> to show the URL of the file or the image in your text.
-- `%INCLUDE{"SomeTopic"}%` : Server side include, includes another topic. The current %WIKITOOLNAME% web is the default web. Example: <code>**%INCLUDE\{"TWiki.SiteMap"\}%**</code>
+- `%INCLUDE{"SomeTopic"}%` : Server side include, includes another topic. The current web is the default web. Example: <code>**%INCLUDE\{"TWiki.SiteMap"\}%**</code>
-- `%SEARCH{"sushi"}%` : Inline search showing the search result embedded in a topic. [[FormattedSearch]] gives you control over formatting, used to create web-based applications.
+- `%SEARCH{"sushi"}%` : Inline search showing the search result embedded in a topic. [[FormattedSearch]] gives you control over formatting, useful for creating web-based applications.
-- [[TWikiPreferences]] defines site-wide variables. Among others:
- - **Line break:** Write <code><span><font>%BR%</font></span></code> to start a new line.
- - **Colored text:** Write: <code><span><font> %RED% Red %ENDCOLOR% and %BLUE% blue %ENDCOLOR% colors</font></span></code> to get: %RED% Red %ENDCOLOR% and %BLUE% blue %ENDCOLOR% colors.
- - **Documentation Graphics:** Write: <code><span><font> %H% Help, %T% Tip, %X% Alert</font></span></code> to get: %H% Help, %T% Tip, %X% Alert. For more info see [[TWikiDocGraphics]].
+- [[TWikiPreferences]] defines some site-wide variables. Among others:
+ - **Line break:** Write `%BR%` to start a new line.
+ - **Colored text:** Write: `%RED% Red %ENDCOLOR% and %BLUE% blue %ENDCOLOR% colors` to get: %RED% Red %ENDCOLOR% and %BLUE% blue %ENDCOLOR% colors.
+ - **Documentation Graphics:** Write: `%H% Help, %T% Tip, %X% Alert` to get: %H% Help, %T% Tip, %X% Alert. For more info see [[TWikiDocGraphics]].
- There are many more variables, see **[[TWikiVariables]]**.
-- To "escape" a variable, prefix it with an exclamation point. Write: <code><span><font> !%SOMEVARIABLE% </font></span></code> to get: %SOMEVARIABLE%.
+- To "escape" a variable, prefix it with an exclamation mark. Write: `!%SOMEVARIABLE%` to get: %SOMEVARIABLE%.
## <a name="TWikiPlugin Formatting Extension"></a><a name="_TWikiPlugin Formatting Extensio"></a> TWikiPlugin Formatting Extensions
-Plugins provide additional text formatting capabilities and can extend the functionality of %WIKITOOLNAME% into many other areas. For example, the optional [SpreadSheetPlugin](http://twiki.org/cgi-bin/view/Plugins/SpreadSheetPlugin) lets you create a spreadsheet with the same basic notation used in TWiki tables.
+Plugins can extend the functionality of TWiki into many other areas. There are a huge number of TWiki plugins available from the [Plugins](http://twiki.org/cgi-bin/view/Plugins) web on TWiki.org.
-Available Plugins are located in the [Plugins](http://twiki.org/cgi-bin/view/Plugins) web on TWiki.org. Currently enabled plugins on this TWiki installation, as listed by `%PLUGINDESCRIPTIONS%`:
+Currently enabled plugins on this TWiki installation, as listed by `%PLUGINDESCRIPTIONS%`:
- [[SpreadSheetPlugin]] <span>(any TWiki, 10197)</span>:
- [[CommentPlugin]] <span>(Dakar, 11359)</span>: Allows users to quickly post comments to a page without an edit/preview/save cycle
- **Q:** Why is the `'&'` character sometimes not displayed?
- **A:** The `'&'` character has a special meaning in HTML, it starts a so called character entity, i.e. `'©'` is the `©` copyright character. You need to escape `'&'` to see it as it is, so write `'&'` instead of `'&'`. <br /> Example: Type `'This & that'` to get `'This & that'`.
-
--- TWiki:Main.MikeMannix - 02 Dec 2001 <br /> -- TWiki:Main.PeterThoeny - 01 Aug 2004