\documentclass{article}
\usepackage{ulem}
\pagestyle{headings}
\begin{document}
\part{Sample Page for Wiki Markup}
\tableofcontents

Sample Page for Wiki MarkupGeneral NotesInline FormattingLiteral TextHeadingsLevel 3 HeadingLevel 4 HeadingLevel 5 HeadingLevel 6 HeadingText AlignmentTable of ContentsHorizontal RulesListsBullet ListsNumbered ListsMixing Bullet and Number List ItemsDefinition ListsBlock QuotesLinks and ImagesWiki LinksInterwiki LinksPHP Manual LinksURLsOn-Page LinksImagesApplication ContentApplication BlocksApplication LinksCode BlocksHTML MarkupTables

\section{General Notes}
The markup described is a combination of the WikkTikkiTavi\footnote{http://tavi.sourceforge.net} and coWiki\footnote{http://develnet.org/} markup styles.

All text is entered as plain text, and will be converted to HTML entities as necessary.  This means that \texttt{<}, \texttt{>}, \texttt{\&}, and so on are converted for you (except in special situations where the characters are Wiki markup; the Wiki is generally smart enough to know when to convert and when not to).

Just hit "return" twice to make a paragraph break.  If you want to keep the same logical line but have to split it across two physical lines (such as when your editor only shows a certain number of characters per line), end the line with a backslash \texttt{\\} and hit return once.  This will cause the two lines to be joined on display, and the backslash will not show.  (If you end a line with a backslash and a tab or space, it will \textit{not} be joined with the next line, and the backslash will be printed.)

\section{Inline Formatting}
\begin{tabular}{|l|l|}
\hline
\texttt{Raw: //emphasis text//} & \textsl{emphasis text}\\
\hline
\texttt{Raw: **strong text**} & \textbf{strong text}\\
\hline
\texttt{Raw: //**emphasis and strong**//} & \textsl{\textbf{emphasis and strong}}\\
\hline
\texttt{Raw: '''bold text'''} & \textbf{bold text}\\
\hline
\texttt{Raw: ''italic text''} & \textit{italic text}\\
\hline
\texttt{Raw: \_\_underline text\_\_} & \underline{underline text}\\
\hline
\texttt{Raw: \{\{teletype text\}\}} & \texttt{teletype text}\\
\hline
\texttt{Raw: ,,subscript,, text} & _{subscript} text\\
\hline
\texttt{Raw: \^\^superscript\^\^ text} & Superscript: NIsuperscriptSuperscript: NI text\\
\hline
\texttt{Raw: @@--- delete text +++ insert text @@} & \sout{ delete text }\underline{ insert text }\\
\hline
\texttt{Raw: @@--- delete only @@} & \sout{ delete only }\\
\hline
\texttt{Raw: @@+++ insert only @@} & \underline{ insert only }\\
\hline
\texttt{Raw: \#\#red|red text\#\# } & Colortext: NIred textColortext: NI\\
\hline
\texttt{Raw: \#\#FFFF00|yellow text\#\#} & Colortext: NIyellow textColortext: NI\\
\hline
\end{tabular}
\section{Literal Text}
If you don't want the wiki to parse some text, enclose it in two backticks (not single-quotes).

\begin{verbatim}


This //text// gets **parsed**.

``This //text// does not get **parsed**.``

\end{verbatim}

This \textsl{text} gets \textbf{parsed}.

Raw: This //text// does not get **parsed**.

\section{Headings}
You can make various levels of heading by putting plus-signs before the text (all on its own line):

\begin{verbatim}


+++  Level 3 Heading

++++ Level 4 Heading

+++++  Level 5 Heading

++++++ Level 6 Heading
\end{verbatim}

\subsection{Level 3 Heading}
\subsubsection{Level 4 Heading}
\paragraph{Level 5 Heading}
\subparagraph{Level 6 Heading}
\section{Text Alignment}
You can center align paragraphs by starting it with an equal sign.

\begin{verbatim}

= Center aligned text
\end{verbatim}

Center: NICenter aligned textCenter: NI

\section{Table of Contents}
To create a list of every heading, with a link to that heading, put a table of contents tag on its own line.

\begin{verbatim}

[[toc]]
\end{verbatim}

\section{Horizontal Rules}
Use four dashes (\texttt{Raw: ----}) to create a horizontal rule.


\noindent\rule{\textwidth}{1pt}
\section{Lists}
\subsection{Bullet Lists}
You can create bullet lists by starting a paragraph with one or more asterisks.

\begin{verbatim}

* Bullet one
 * Sub-bullet
\end{verbatim}

\begin{itemize}
\item{Bullet one}
\begin{itemize}
\item{Sub-bullet}
\end{itemize}
\end{itemize}
\subsection{Numbered Lists}
Similarly, you can create numbered lists by starting a paragraph with one or more hashes.

\begin{verbatim}

# Numero uno
# Number two
 # Sub-item
\end{verbatim}

\renewcommand{\labelenumi}{\arabic{enumi}}
\begin{enumerate}
\item{Numero uno}
\item{Number two}
\renewcommand{\labelenumi}{\arabic{enumii}}
\begin{enumerate}
\item{Sub-item}
\end{enumerate}
\end{enumerate}
\subsection{Mixing Bullet and Number List Items}
You can mix and match bullet and number lists:

\begin{verbatim}

# Number one
 * Bullet
 * Bullet
# Number two
 * Bullet
 * Bullet
  * Sub-bullet
   # Sub-sub-number
   # Sub-sub-number
# Number three
 * Bullet
 * Bullet
\end{verbatim}

\renewcommand{\labelenumi}{\arabic{enumi}}
\begin{enumerate}
\item{Number one}
\begin{itemize}
\item{Bullet}
\item{Bullet}
\end{itemize}
\item{Number two}
\begin{itemize}
\item{Bullet}
\item{Bullet}
\begin{itemize}
\item{Sub-bullet}
\renewcommand{\labelenumi}{\arabic{enumiiii}}
\begin{enumerate}
\item{Sub-sub-number}
\item{Sub-sub-number}
\end{enumerate}
\end{itemize}
\end{itemize}
\item{Number three}
\begin{itemize}
\item{Bullet}
\item{Bullet}
\end{itemize}
\end{enumerate}
\subsection{Definition Lists}
You can create a definition (description) list with the following syntax:

\begin{verbatim}

: Item 1 : Something
: Item 2 : Something else
\end{verbatim}

\begin{description}
\item[Item 1] {Something}
\item[Item 2] {Something else}
\end{description}

\section{Block Quotes}
You can mark a blockquote by starting a line with one or more '>' characters, followed by a space and the text to be quoted.

\begin{verbatim}

This is normal text here.

> Indent me! The quick brown fox jumps over the lazy dog. Now this the time for all good men to come to the aid of their country. Notice how we can continue the block-quote in the same "paragraph" by using a backslash at the end of the line.
>
> Another block, leading to...
>> Second level of indenting.  This second is indented even more than the previous one.

Back to normal text.
\end{verbatim}

This is normal text here.

\begin{quote}
Indent me! The quick brown fox jumps over the lazy dog. Now this the time for all good men to come to the aid of their country. Notice how we can continue the block-quote in the same "paragraph" by using a backslash at the end of the line.\newline
\end{quote}

>\newline
\begin{quote}
Another block, leading to\ldots\newline
\begin{quote}
Second level of indenting.  This second is indented even more than the previous one.\newline
\end{quote}

\end{quote}

\newline
Back to normal text.\section{Links and Images}
\subsection{Wiki Links}
SmashWordsTogether\footnote{http://example.com/index.php?page=SmashWordsTogether} to create a page link.

You can force a Wiki page name \textbf{not} to be clickable by putting an exclamation mark in front of it.

\begin{verbatim}

SmashWordsTogether !SmashWordsTogether
\end{verbatim}

SmashWordsTogether\footnote{http://example.com/index.php?page=SmashWordsTogether} SmashWordsTogether

You can force a Wiki page to be clickable even if it does \textbf{not} match the page name format by putting the name in parentheses.

\begin{verbatim}

((Wiki/Page))
\end{verbatim}

Wiki/Page\footnote{http://example.com/index.php?page=Wiki/Page}

You can also use this format to create a "described" or "labeled" link or to add an anchor target.

\begin{verbatim}

((Wiki/Page|Descriptive text for the link.#anchor))
\end{verbatim}

Descriptive text for the link.\footnote{http://example.com/index.php?page=Wiki/Page#anchor}

You can alternatively create a "described" or "labeled" link to a wiki page by putting the page name in brackets, followed by some text.

\begin{verbatim}

[Wiki/Page Descriptive text for the link.]
\end{verbatim}

[Wiki/Page Descriptive text for the link.]

\subsection{Interwiki Links}
Interwiki links are links to pages on other Wiki sites. Type the \texttt{Raw: SiteName:PageName} like this:

\begin{itemize}
\item{MeatBall:RecentChanges\footnote{http://www.usemod.com/cgi-bin/mb.pl?RecentChanges}}
\item{Advogato:proj/WikkiTikkiTavi\footnote{http://advogato.org/proj%2FWikkiTikkiTavi}}
\item{Wiki:WorseIsBetter\footnote{http://c2.com/cgi/wiki?WorseIsBetter}}
\end{itemize}
\subsection{PHP Manual Links}
PHP manual links are links to the PHP manual on the php.net web site.

\begin{verbatim}

[[php strtolower]]
\end{verbatim}

Phplookup: NI

\subsection{URLs}
Create a remote link simply by typing its URL: http://www.horde.org\footnote{http://www.horde.org}.

If you like, enclose it in brackets to create a numbered reference and avoid cluttering the page; \texttt{Raw: [http://www.horde.org/]} becomes 1\footnote{http://www.horde.org/}.

Or you can have a described-reference instead of a numbered reference:\newline
\begin{verbatim}

[http://www.horde.org Horde]
\end{verbatim}

\newline
Horde\footnote{http://www.horde.org}\subsection{On-Page Links}
Create an anchor on the page by \texttt{Raw: [[\# anchorName nice anchor text]]} nice anchor text and refer to it by \texttt{Raw: \#anchorName} \#anchorName, or \texttt{Raw: [\#anchorName use normal link renaming]} [\#anchorName use normal link renaming].

\subsection{Images}
You can put a picture in a page with \texttt{Raw: [[image foo.jpg]]}. You can use any file type, but most browsers only support GIF, JPEG, and PNG formats. The filename can either be a relative reference (in which case the wiki looks for a file attached to the current page - or a different wiki page if the file name is prefixed with a page name, e.g. \texttt{Raw: [[image SomePage:foo.jpg]]}), an absolute reference which begins with a slash (in which case the wiki uses it to retrieve a file relative to the web server's root), or a full, external URL.

Additional attributes, such as "alt" can follow the image filename or URL like so: \texttt{Raw: [[image foo.jpg alt="A Foo JPEG"]]}.  "link" is a special attribute which makes the image a link to the specified URL.

\section{Application Content}
\subsection{Application Blocks}
Content from other Horde applications provided by portal blocks can be embedded into a page using \texttt{[[block]]} tags.

To include Horde's moon phases block for example:

\begin{verbatim}

[[block horde/Moon phase=next hemisphere=northern]]
\end{verbatim}

[[block horde/Moon phase=next hemisphere=northern]]

\subsection{Application Links}
Links to other Horde applications is supported if those applications support API links. The Wiki itself supports such an API to link to individual wiki pages:

\begin{verbatim}

[[link Link to some other wiki page|wiki/show page=Wiki/Page]]
\end{verbatim}

[[link Link to some other wiki page|wiki/show page=Wiki/Page]]

\section{Code Blocks}
Create code blocks by using \texttt{<code>\ldots</code>} tags (each on its own line).

\begin{verbatim}

This is an example code block!
\end{verbatim}

To create PHP blocks that get automatically colorized when you use PHP tags, simply surround the code with \texttt{<code type="php">\ldots</code>} tags (the tags themselves should each be on their own lines, and no need for the \texttt{<?php \ldots ?>} tags).

\begin{verbatim}

 <code type="php">
 // Set up the wiki options
 $options = array();
 $options['view_url'] = "index.php?page=";

 // load the text for the requested page
 $text = implode('', file($page . '.wiki.txt'));

 // create a Wiki objext with the loaded options
 $wiki = new Text_Wiki($options);

 // transform the wiki text.
 echo $wiki->transform($text);
 </code>
\end{verbatim}

\begin{verbatim}

// Set up the wiki options
$options = array();
$options['view_url'] = "index.php?page=";

// load the text for the requested page
$text = implode('', file($page . '.wiki.txt'));

// create a Wiki objext with the loaded options
$wiki = new Text_Wiki($options);

// transform the wiki text.
echo $wiki->transform($text);
\end{verbatim}

API references can be generated using \texttt{<function>} tags.

\begin{verbatim}

<function>
name:listUsers
access:public
param:string,Filter users by this string.,'USER'
returns:array
throws:Exception,if user backend not available.
</function>
\end{verbatim}

\textsl{Rendering of this rule is broken as of Text\_Wiki 1.2.1, usage is discouraged.}

\section{HTML Markup}
You can add native HTML markup using \texttt{<html>\ldots</html>} tags.

\begin{verbatim}

<html>
<div style="border:2px double blue"><strong>HTML</strong></div>
</html>
\end{verbatim}

\textsl{This rule is disabled by default.}

<html>\newline
<div style="border:2px double blue"><strong>HTML</strong></div>\newline
</html>

\section{Tables}
You can create tables using pairs of vertical bars:

\begin{verbatim}

||~ Heading one ||~ Heading two ||
|| cell one || cell two ||
|||| big ol' line ||
|| cell four || cell five ||
|| cell six || here's a very long cell ||
\end{verbatim}

\begin{tabular}{|l|l|}
\hline
Heading one & Heading two\\
\hline
cell one & cell two\\
\hline
\multicolumn{2}{|l|}{big ol' line}\\
\hline
cell four & cell five\\
\hline
cell six & here's a very long cell\\
\hline
\end{tabular}
\begin{verbatim}

|| lines must start and end || with double vertical bars || nothing ||
|| cells are separated by || double vertical bars || nothing ||
|||| you can span multiple columns by || starting each cell ||
|| with extra cell |||| separators ||
|||||| but perhaps an example is the easiest way to see ||
\end{verbatim}

\begin{tabular}{|l|l|l|}
\hline
lines must start and end & with double vertical bars & nothing\\
\hline
cells are separated by & double vertical bars & nothing\\
\hline
\multicolumn{2}{|l|}{you can span multiple columns by} & starting each cell\\
\hline
with extra cell & \multicolumn{2}{l|}{separators}\\
\hline
\multicolumn{3}{|l|}{but perhaps an example is the easiest way to see}\\
\hline
\end{tabular}
\end{document}
