Jump to content

MediaWiki:MapMenu.js: Difference between revisions

Make linkify() dynamic based on wgContentLanguage
(Added SAR to Macau and Hong Kong)
(Make linkify() dynamic based on wgContentLanguage)
Line 1,973: Line 1,973:
function linkify(str) {
function linkify(str) {
     // e.g. "https://beta.familysearch.org/wiki/en/";
     // e.g. "https://beta.familysearch.org/wiki/en/";
     const base = document.location.origin + '/wiki/en/';
    const lang = mw.config.get('wgContentLanguage');
     const base = document.location.origin + '/wiki/' + lang + '/';
     var n = str.indexOf('[');
     var n = str.indexOf('[');
     // indexOf returns -1 if not found
     // indexOf returns -1 if not found
53,890

edits