Markdown
Text Viewer supports Markdown. More specifically, it uses Showdown, and documentation for that can be found here: http://demo.showdownjs.com/
If the first line starts with "#", the rest of the line will be used as the page title.
Special Strings
These strings will be replaced:
String | Replacement |
---|---|
\n | New Line |
Escaping Text
You can prevent the following characters from being parsed by preceding them with a backslash (\): \ # { } : | * _
So, typing \{{command\}} will display as {{command}}.
URL Parameters
Simply adding "?Example" to the URL will display "Example".
To get more complex, use these parameters:
Parameter | Description |
---|---|
?text= | Text to be parsed and displayed |
?title= | Text to replace the page title |
Commands
Commands can be used to spice up your text.
Possible formats:
- {{command}}
- {{command:arg1|arg2|arg3|...}}
- {{command|arg1|arg2|arg3|...}}
Required, Optional
Command | Description |
---|---|
{{char:text|position}} | Character at a position in the string. (Starting at 0) |
{{choose:option1|option2|...}} {{choose:option1,option2,...}} |
Picks a random item from a selection. |
{{comment:text}} {{#:text}} |
Does not display. |
{{error:message}} | Displays an error message. |
{{if:text-to-test|condition=result|else=result}} {{if:number|<condition=result|else=result}} {{if:number|>condition=result|else=result}} |
Displays text based on conditions. Infinite arguments. |
{{lower:text}} | Converts text to lowercase. |
{{range:min|max}} {{range:min-max}} |
Picks a number from a minimum to a maximum. |
{{repeat:text|amount}} | Repeat text. |
{{replace:text|find|replace-with}} | Replaces text with another. |
{{replacedict:text|find=replace-with|...}} | Replaces multiple strings at once. Infinite arguments. |
{{title:text}} | Converts text to Title Case. |
{{upper:text}} | Converts text to UPPERCASE. |
{{wrap:text|wrapper}} | Adds a string to both sides of text. |