interwiki
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
interwiki [2022-01-17 12:06] – [Inter(n)wiki links] asimong | interwiki [2024-01-20 20:34] (current) – usemod.com expired 212.159.76.45 | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== InterWiki Links ====== | ====== InterWiki Links ====== | ||
- | The original idea of InterWiki was to have one large distributed [[wp> | + | The original idea of InterWiki was to have one large distributed [[wp> |
- | In [[DokuWiki]] this is done by prefixing Wiki [[pagenames]] with a shortcut separated by a ''>'' | + | In [[DokuWiki]] this is done by prefixing Wiki [[pagenames]] with a shortcut separated by a **''>'' |
Examples: | Examples: | ||
- | | %%[[wp>InterWiki]]%% | [[wp>InterWiki]] | links to the English language Wikipedia | + | ^ Shortcut |
- | | %%[[phpfn>random]]%% | [[phpfn>random]] | links to a function in the PHP manual | + | | '' |
- | | %%[[google> | + | | '' |
- | | %%[[doku>interwiki]]%% | [[doku>interwiki]] | links to the DokuWiki wiki | + | | '' |
- | | %%[[skype> | + | | '' |
- | | %%[[this> | + | | '' |
+ | | '' | ||
+ | | '' | ||
+ | | '' | ||
+ | | '' | ||
+ | | '' | ||
+ | | '' | ||
+ | | '' | ||
+ | | '' | ||
+ | | '' | ||
+ | | '' | ||
- | Here's an example of how to access an arbitrary file in dokuwiki's data/media directory by clicking on an image. It's useful for videos and pdf files. | + | Here's an example of how to access an arbitrary file in DokuWiki's data/media directory by clicking on an image. It's useful for videos and PDF files. |
[[this> | [[this> | ||
- | Since DokuWiki [[changes# | + | Interwiki |
- | {{ phpfn> | + | {{ phpfn> |
{{ phpfn> | {{ phpfn> | ||
Line 26: | Line 36: | ||
InterWiki shortcuts are defined in two files: | InterWiki shortcuts are defined in two files: | ||
- | * the '' | + | * Default included links are in '' |
- | * the ''< | + | * Local modifications in ''< |
+ | |||
+ | Alternatively, | ||
The interwiki shortcut has to be in lowercase and follow the [[pagename]] rules. | The interwiki shortcut has to be in lowercase and follow the [[pagename]] rules. | ||
Line 33: | Line 45: | ||
The format of the interwiki config file is: | The format of the interwiki config file is: | ||
- | | + | <code - conf/ |
+ | < | ||
+ | </ | ||
+ | |||
+ | Modify existing interwiki links, by reusing the shortcut:< | ||
+ | wp | ||
+ | </ | ||
+ | Or disable by mentioning no link< | ||
+ | wpmeta | ||
+ | paypal | ||
+ | </code> | ||
The shortcut is the one you will be able to use in the link later. In the URL you can use some placeholders to be more flexible in linking. If no placeholder is given the [[phpfn> | The shortcut is the one you will be able to use in the link later. In the URL you can use some placeholders to be more flexible in linking. If no placeholder is given the [[phpfn> | ||
Line 47: | Line 69: | ||
The last 5 parameters are useful when creating interwikilinks to cachesystems. | The last 5 parameters are useful when creating interwikilinks to cachesystems. | ||
+ | |||
+ | For configuration changes to take effect on the pages, the [[devel: | ||
+ | |||
+ | ==== Examples ==== | ||
For example cached links with the old, not longer working, [[wp> | For example cached links with the old, not longer working, [[wp> | ||
- | < | + | < |
+ | coral http:// | ||
+ | </ | ||
For example, [[https:// | For example, [[https:// | ||
- | < | + | < |
+ | ubuntu | ||
+ | </ | ||
and now create your link to it like this: | and now create your link to it like this: | ||
Line 66: | Line 96: | ||
To refer to certain namespaces within you own wiki: | To refer to certain namespaces within you own wiki: | ||
- | < | + | < |
+ | < | ||
+ | </ | ||
+ | |||
+ | For example: <code - conf/ | ||
+ | enlib | ||
+ | </ | ||
- | For example: '' | ||
===== Configuring InterWiki Shortcut Icons ===== | ===== Configuring InterWiki Shortcut Icons ===== | ||
Line 84: | Line 119: | ||
If you want to disable all or some kind of link icons, refer to [[tips: | If you want to disable all or some kind of link icons, refer to [[tips: | ||
- | ===== Tip ===== | + | ===== Using the number sign/hash (#), not as comment |
- | ==== Hashtag | + | Because it is reserved to mark a comment line, a hash (''#'' |
- | If you are using the name of your interwiki in the fragment part of your URL, you need to escape it. | + | |
+ | e.g. if you are using the name of your interwiki in the fragment part of your URL, you need to escape it. | ||
Example: | Example: | ||
- | * Configuration | + | * Configuration< |
- | < | + | |
postconf | postconf | ||
</ | </ | ||
- | * Usage | + | * Usage< |
- | < | + | |
[[postconf> | [[postconf> | ||
</ | </ | ||
- | + | ===== See also ===== | |
- | =====See also===== | + | |
* [[tips: | * [[tips: | ||
+ | * You can install and use the [[plugin: | ||
* [[config|Configuring DokuWiki]] | * [[config|Configuring DokuWiki]] | ||
+ |
interwiki.1642417565.txt.gz · Last modified: 2022-01-17 12:06 by asimong