Good suggestion! But with the {{SERVER}} variable I can't add
relative links.
[{{SERVER}}/myPage My Page] works
but
[{{SERVER}}../../myPage My Page] doesn't work.
It seems that a "/" must be the first character after {{SERVER}}.
A second problem (for me):
My SERVER variable is empty ($wgServer=''). This is needed for me
because I am using mediawiki behind a mod_proxy Apache. I want to
hide the FQDN, since this depends on the interface I am using. I have
three IP interfaces in that machine. And the reverse proxy doesn't
like the server name in the URL.
If SERVER is a null string
[{{SERVER}}/myPage My Page] doesn't work.
Ralf
On Monday 17 October 2005 13:17, Rowan Collins wrote:
On 17/10/05, ralf-buero(a)kruedewagen.de
<ralf-buero(a)kruedewagen.de>
wrote:
But then let
me ask how I can add a link to mediawiki, which will
then be parsed to
<a href="../../foo">Foo Pages</a>
I think there should be an official way to link from the wiki to
another (virtual) server on the same box. I would name this a
"relative link".
This was in my last e-mail, but I did fear it might get lost under
the other stuff:
You can use MediaWiki's {{SERVER}} variable to do exactly this -
basically, "[{{SERVER}}/myPage My Page]" should work. See
http://meta.wikimedia.org/Help:Variable for details and other
available varaibles.
To clarify, {{SERVER}} expands to the FQDN, so this does
*server-side* what you were relying on happening client-side. [Of
course, when you're coding HTML, you would just use a standard
relative link, as in <a href="/myPage">, but that's hard to parse
in the context of wiki-markup, and the result is essentially the
same]
--
Rowan Collins BSc
[IMSoP]
_______________________________________________
MediaWiki-l mailing list
MediaWiki-l(a)Wikimedia.org
http://mail.wikipedia.org/mailman/listinfo/mediawiki-l
--
Ralf Kruedewagen
Systems Integration
Ericsson GmbH, Germany
Tel: +49-211-534-2640
Fax: +49-211-534-3743
Mobile: +49-172-2166741
mailto:Ralf.Kruedewagen@ericsson.com