Links
You can add both external links and internal links to your page. The general syntax for links is to wrap the url inside 2 square brackets. Links can have an optional title, which is what the link will be displayed as.
[[ url or page id | optional title ]]
External links
External links are links to pages outside your wiki. Here is a link to the polifonic home page:
[[http://www.polifonic.io]] | http://www.polifonic.io |
You can specify a title, which is what the link will be displayed as.
[[http://www.polifonic.io|The polifonic home page]] | The polifonic home page |
Of course, links can be embedded inline (i.e. inside the body of your text.
This is a link to the [[http://www.polifonic.io|the polifonic home page]]. | This is a link to the the polifonic home page. |
For external links, the square brackets are optional. You can just type the url directly, and polifonic will recognize it as an external link. Obviously, you cannot specify a title that way.
https://www.polifonic.io | https://www.polifonic.io |
Internal links
Internal links are links to pages from your own wiki. To add an internal link, enclose the id of the target page in square brackets. This markup: %%[[start]]%%
will result in this display: Wiki syntax .
As you can see above, polifonic will display the link using the title of the page.
You can also explicitly specify a title. This will override the title of the page when displaying the link. This markup: %%[[start|Syntax home page]]%%
will result in this link: Syntax home page .
Linking to a non-existent page
The target page does not need to exist in order to create a internal link. In fact, this is the recommended way to create a new page: first create a link to the page you want to create, then click on that link to create the new page. A link to a non-existent page will be displayed using a special style, typically in red (this may vary depending on the theme you've chosen for you wiki, but most themes will follow a common semantics). For example: no_such_page .
Namespaces
If you use a simple id in your markup, then polifonic will assume the link is to a page of that id in the same namespace as the current page. As in the example above, this markup: %%[[no_such_page]]%%
assumes the page referred to is the page with id %%no_such_page%%
in the namespace of the current page, which is %%syntax%%
. The link is displayed using the full id of the target page, i.e. %% syntax:no_such_page%%
(that's because the page doesn't exist yet).
To link to a page in another namespace, use the full id (namespace + page id concatenated with a colon) of the page. This markup: %%[[page:start]]%%
will link to the %%start%%
page in the %%page%%
namespace: Creating content . In this case, because the page already exists, and we did not specify a title for the link, the link is displayed using the page's title.
You can also use relative page ids.
Email links
You can add email links to your wiki pages. The following are examples of the supported syntax. All will display as test@example.com.
%%[[test@example.com]]%%
%%test@example.com%%
%%[[<test@example.com>]]%%
%%[[<test@example.com>]]%%
You can add a title, which will be used when displaying the link:
%%[[test@example.com|email me]]%%
%%[[<test@example.com>|email me]]%%
%%[[<test@example.com>|email me]]%%
are equivalent and will all display as email me.