diff options
-rw-r--r-- | TWiki/TextFormattingRules.mdwn | 41 |
1 files changed, 27 insertions, 14 deletions
diff --git a/TWiki/TextFormattingRules.mdwn b/TWiki/TextFormattingRules.mdwn index 6317196c..ae88f32d 100644 --- a/TWiki/TextFormattingRules.mdwn +++ b/TWiki/TextFormattingRules.mdwn @@ -4,6 +4,8 @@ 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 layed out below - refer back to this page in a pop-up window from the **Edit** screen. +<a name="TWikiShorthand"></a> + ## <a name="TWiki_Editing_Shorthand"> TWiki Editing Shorthand </a> <table bgcolor="#000000" border="0" cellpadding="3" cellspacing="1"> @@ -212,7 +214,7 @@ Know.ReadmeFirst </td> </tr> <tr bgcolor="#ffffff"> - <td valign="top"><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; i.e. <code>[<nop>[text formatting FAQ]]</nop></code> links to topic <span style="background:"><font color="">Text Formatting FAQ</font></span><a href="http://LOCATION/TextFormattingFAQ">?</a>. You can also refer to a different web and use anchors. </td> + <td valign="top">#SquareBrackets <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; i.e. <code>[<nop>[text formatting FAQ]]</nop></code> links to topic <span style="background:"><font color="">Text Formatting FAQ</font></span><a href="http://LOCATION/TextFormattingFAQ">?</a>. You can also refer to a different web and use anchors. </td> <td valign="top"><span style="background: #FFFFCC"><font color="#990000"> <pre> [[wiki syntax]] @@ -255,36 +257,49 @@ Know.ReadmeFirst ## <a name="Using_HTML"> </a> Using HTML -Most HTML tags will work, but it's almost always preferable not to use HTML, so that the markup remains easy for everyone to edit. +You can use just about any HTML tag without a problem - however, to keep in mind: + +* On collaboration pages, it's preferable NOT to use HTML, and to use TWiki shorthand instead - this keeps the text uncluttered and easy to edit. + * **_NOTE:_** 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. + * **_NOTE:_** The standard installation TWiki is compatible across a wide range of browsers and computer platforms. If this is important to you, remember that using browser-specific tags or any other mark-up that doesn't degrade well will reduce compatibility. ## <a name="Hyperlinks"> Hyperlinks </a> -Being able to create links without any formatting required is a core TWiki feature, made possible using [[WikiNames]]. With the latest version of TWiki linking rules, a simple extension of the syntax provides an new set of flexible linking options. +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. ### <a name="Internal_Links"> Internal Links </a> * [[GoodStyle]] is a [[WikiWord]] that links to the GoodStyle topic located in the current %WIKITOOLNAME% web. -* [[NotExistingYet]] is a topic waiting to be written. You could create that topic by clicking on the question mark. (Do not create that topic; you would wreck this example!) + +* [[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!) ### <a name="External_Links"> External Links </a> * `http://...`, `https://...`, `ftp://...` and `mailto:...@...` are linked automatically. + * Email addresses like `name@domain.com` are linked automatically. +* <code>[[Square bracket rules]]</code> let you easily create non-WikiWord links. + ## <a name="TWiki_Variables"> TWiki Variables </a> -Variables are names that are enclosed in percent signs; they get expanded on the fly. +Variables are names that are enclosed in percent signs `%` that are expanded on the fly. + +* <code>%TOC%</code> : Automatically generates a table of contents based on headings in a topic - see the top of this page for an example. + +* <code>%WEB%</code> : The current web, is **%WEB%**. + +* <code>%TOPIC%</code> : The current topic name, is **%TOPIC%**. -* <code>%TOC%</code> : The table of content, is based on headings in a topic. -* <code>%WEB%</code> : The current web, is **%WEB%** . -* <code>%TOPIC%</code> : The current topic name, is **%TOPIC%** . * <code>%ATTACHURL%</code> : 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. + * <code>%INCLUDE\{"SomeTopic"\}%</code> : Server side include, includes another topic. The current %WIKITOOLNAME% web is the default web. Example: <code>**%INCLUDE\{"%TWIKIWEB%.TWikiWebsTable"\}%**</code> -* There are many more variables, see [[TWikiVariables]]. -## <a name="_Gotchas_when_Editing_Text"> "Gotchas" when Editing Text </a> +* There are many more variables, see **[[TWikiVariables]]**. -The formatting rules are fairly simple to use and fast to type. However, there are some things to watch out for: +## <a name="Common_Editing_Errors"> Common Editing Errors </a> + +TWiki formatting rules are fairly simple to use and quick to type. However, there are some things to watch out for, taken from the [[TextFormattingFAQ]]: * **Q:** Text enclosed in angle brackets like `<filename>` is not displayed. How can I show it as it is? * **A:** The `'<'` and `'>'` characters have a special meaning in HTML, they define HTML tags. You need to escape them, so write `'<'` instead of `'<'`, and `'>'` instead of `'>'`. <br /> Example: Type `'prog <filename>'` to get `'prog <filename>'`. @@ -292,11 +307,9 @@ The formatting rules are fairly simple to use and fast to type. However, there a * **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'`. -* See more [[TextFormattingFAQs]] - ## <a name="TWiki_Plugins"> TWiki Plugins </a> -Plugins provide additional text formatting rules and can extend the functionality of %WIKITOOLNAME% into many other areas. Available Plugins are located in the [[TWikiPlugins]] web. Currently enabled plugins on this site are: +Plugins provide additional text formatting capabilities and can extend the functionality of %WIKITOOLNAME% into many other areas. For example, one optional Plugin lets you create a basic spreadsheet in a similar way to tables. Available Plugins are located in the [[TWikiPlugins]] web on TWiki.org. Currently enabled plugins on here: %PLUGINDESCRIPTIONS% |