Page MenuHomePhabricator

Proposal: a new variable {{SERVER_EXTERN}}
Closed, DeclinedPublic

Description

We already have {{SERVER}}.

This variable can have different values depending on how the wiki is accessed.
Examples: http://localhost , http://internal.network or http://www.domain.tld

In e-mails sent by the wiki (especially enotifs) and in the text templates for
them, it would be useful to have a fixed variable, which the Sysop can set to
{{SERVER}} (installation default) or to a different value, which then reflects
the external server address such as http://www.domain.tld and is substituted.

I hereby propose to implement an additional variable with the name
{{SERVER_EXTERN}} which can be used by the wiki software internally (example:
UserMailer.php), MediaWiki: pages and any wiki page


Version: 1.5.x
Severity: enhancement

Details

Reference
bz3249

Related Objects

Event Timeline

bzimport raised the priority of this task from to Lowest.Nov 21 2014, 8:47 PM
bzimport added a project: MediaWiki-Parser.
bzimport set Reference to bz3249.
bzimport added a subscriber: Unknown Object (MLST).

(In reply to comment #0)

I hereby propose to implement an additional variable with the name
{{SERVER_EXTERN}} which can be used by the wiki software internally (example:
UserMailer.php), MediaWiki: pages and any wiki page

  • The value needs to be defined either in LocalSettings.php or in a page

[[MediaWiki:SERVER_EXTERN]]

  • default value (installation) = {{SERVER}}

i.e. {{SERVER_EXTERN}} follows the value of {{SERVER}} except when a different
value is given in LocalSettings.php or [[MediaWiki:SERVER_EXTERN]]

Created attachment 828
patch against REL1_5

The small patch implements a new variable {{SERVER_EXTERN}}.
Its value follows the value of MediaWiki:server_extern (default = {{SERVER}})

Usage:
to allow a fixed wiki server address in e-mail notifications, regardless, how
the wiki was actually accessed (localhost, intranet, internet) by the page
editor.

Attached: