Skip to content

Commit

Permalink
Bugfix: correct help page link for interwiki links
Browse files Browse the repository at this point in the history
  • Loading branch information
sbrl committed Sep 10, 2023
1 parent ed4bda5 commit b2b9606
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
4 changes: 3 additions & 1 deletion Changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@ This file holds the changelog for Pepperminty Wiki. This is the master list of t


## v0.25-dev (unreleased)
This is the next release of Pepperminty Wiki. We'll list changes here as we work on them.
This is the next release of Pepperminty Wiki, that hasn't been released yet.

- **Fixed:** Fixed link to the interwiki links documentation on the help page if interwiki links have not yet been setup.


## v0.24
Expand Down
10 changes: 5 additions & 5 deletions modules/feature-interwiki-links.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
<?php
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */

register_module([
"name" => "Interwiki links",
Expand All @@ -20,7 +20,7 @@
$env->interwiki_index = json_decode(file_get_contents($paths->interwiki_index));
}

$doc_help = "<p>$settings->sitename doesn't currently support interwiki links, but if you'd like it to, please contact ".htmlentities($settings->admindetails_name)." ($settings->sitename's administrator) through their contact details at the bottom of every page and point them at <a href='https://starbeamrainbowlabs.com/labs/peppermint/_docpress/06.5-Interwiki-Links.html'>the documentation on how to set it up</a>. It's really easy, and they can always <a href='https://github.com/sbrl/Pepperminty-Wiki/issues/new'>open an issue</a> if they get stuck :-)</p>\n";
$doc_help = "<p>$settings->sitename doesn't currently support interwiki links, but if you'd like it to, please contact ".htmlentities($settings->admindetails_name)." ($settings->sitename's administrator) through their contact details at the bottom of every page and point them at <a href='https://starbeamrainbowlabs.com/labs/peppermint/__nightdocs/06.5-Interwiki-Links.html'>the documentation on how to set it up</a>. It's really easy, and they can always <a href='https://github.com/sbrl/Pepperminty-Wiki/issues/new'>open an issue</a> if they get stuck :-)</p>\n";
if(!empty($env->interwiki_index)) {
$doc_help = <<<HELP_BLOCK
<p>$settings->sitename supports inter-wiki links. Such a link sends the user elsewhere on the internet. By prefixing a page name with a prefix, the convenience of the internal link syntax described above can be exploited to send users elsewhere without having to type out full urls! Here are few examples (note that these prefixes are only examples, and probably aren't available on $settings->sitename - check the list below for supported prefixes):</p>
Expand Down

0 comments on commit b2b9606

Please sign in to comment.