Extension talk:Interwiki/Archive 1

From MediaWiki.org
Jump to navigation Jump to search
The following discussion has been transferred from Meta-Wiki.
Any user names refer to users of that site, who are not necessarily users of MediaWiki.org (even if they share the same username).

Just a note to say that this works with 1.5 too! Thanks.


Maybe I'm doing something wrong, but is it supposed to produce the database tables for me, or do I have to create them? I keep getting errors that the table it wants doesn't exist. I don't mind editing them manually, but there doesn't appear to be any instructions for doing so... -- 03:09, 23 December 2005 (UTC)

Function error

Doesn't work in the new version(1.5.7) of wikimedia.

I get Fatal error: Call to undefined function: includable() in /extensions/SpecialInterwiki.php on line 65 --Sgrayban 14:37, 24 March 2006 (UTC)

Me too, but mine's: Fatal error: Call to a member function on a non-object in /includes/SkinTemplate.php on line 306 - 05:25, 16 April 2006 (UTC)
Me too - Mediawiki 1.6.3, php 5.1.2, my error is: PHP Fatal error: Call to a member function getID() on a non-object in /usr/local/www/data-dist/mediawiki/includes/SkinTemplate.php on line 306, referer: http://wiki.bitparts.org/index.php/Special:Specialpages 04:32, 20 April 2006 (UTC)
I also get this error: Fatal error: Call to a member function on a non-object in /includes/SkinTemplate.php on line 306 -- 21:29, 21 April 2006 (UTC)

Security fixes

The original version of this code had some bugs, including some security issues:

  • cross-site request forging
  • cross-site scripting via HTML/JavaScript injection
  • SQL injection

Additionally some of the HTML output wasn't well-formed so it would break XML-strict browsers when the wiki is configured for sending the 'real' XHTML Content-Type.

I've made some corrections to the copy on the wiki page:

  • Use of the edit token to protect against forged form submissions
  • Escaping of HTML output to protect against JavaScript injection/XSS
  • Switched from manual SQL (missing escaping) to the database query builder functions which provide safety automatically

Also the bug running on current 1.6 versions is fixed by adding the call to $this->setHeaders(). --brion 08:26, 22 April 2006 (UTC)


Anyone know what the process is on getting this into svn? It seems it would be of much more benefit there. --Ymmotrojam 17:47, 17 August 2006 (UTC)

Seconded. This is such a basic feature it ought to be at least in the Extensions Subversion repository, and probably in the main SVN. I don't know how to request that but I imagine Bugzilla is as good a way as any. Unfortunately Wikimedia's Bugzilla is down right now. --Kingboyk 17:31, 4 January 2007 (UTC)

Read-only version

Upon reflection, this doesn't really fulfill my need. To manipulate the interwiki list I just use phpMyAdmin or MS Access. What I would like - and I think this ought to be built-in Mediawiki - is a read-only list of interwiki links for the benefit of the users.

Anyway I'll have a play and maybe will come up with something I can post back here. --Kingboyk 19:59, 4 January 2007 (UTC)

OK, it's read only for those without privileges ("developer" group in my install). Works fine on 1.8.2 (r18799). --Kingboyk 20:15, 4 January 2007 (UTC)

Dutch translation

If you are interested in more translations, this is the Dutch (nl) translation:

$wgSpecialInterwikiMessages['nl'] = array(
        'interwiki' => 'Interwikidata bekijken en wijzigen',
        'interwiki_delquestion' => '"$1" aan het verwijderen',
        'interwiki_deleted' =>  '$1 is succesvol verwijderd van de interwikitabel.',
        'interwiki_prefix' => 'Prefix',
        'interwiki_prefix2' => 'Prefix:',
        'interwiki_url' => 'URL',
        'interwiki_local' => 'Local',
        'interwiki_trans' => 'Trans',
        'interwiki_delete' => 'Verwijderen',
        'interwiki_yes' => 'Ja',
        'interwiki_delfailed' => '$1 kon niet worden verwijderd van de interwikitabel.',
        'interwiki_added' => '$1 is succesvol toegevoegd aan de interwikitabel.',
        'interwiki_addfailed' => '$1 kon niet worden toegevoegd aan de interwikitabel.',
        'interwiki_log_added' => 'Voegde "$1" ($2) (local: $3) (trans: $4) toe aan de interwikitabel: $5',
        'interwiki_alreadyexists' => '$1 bestaat al in de interwikitabel!',
        'interwiki_log_deleted' => 'Verwijderde prefix "$1" van de interwikitabel: $2',
        'interwiki_add' => '*Een interwikiprefix toevoegen',
        'interwiki_show' => '*Alle interwikiprefixen bekijken',
        'interwiki_logpagename' => 'Logboek interwikitabel',
        'interwiki_logpagetext' => 'Dit is een logboek van wijzigingen aan de interwikitabel.',
        'interwiki_logentry' => '',
        'interwiki_reasonfield' => 'Reden',
        'interwiki_addtext' => 'Een interwikiprefix toevoegen',
        'interwiki_delbutton' => 'Verwijderen',
        'interwiki_addbutton' => 'Toevoegen',

SPQRobin 12:51, 2 September 2007 (UTC)

How to add the translation file

I've added the SpecialInterwiki.i18n.php file, and I have to change something in the SpecialInterwiki.php file, but I don't know what. The information for this is unclear :-( SPQRobin 14:09, 22 September 2007 (UTC)

The necessary update to SpecialInterwiki.php is presented as a diff(1) - and not even one in unified format -, so I agree, it's unclear. Basically, though, all you need to do is replace the two blocks of lines marked with exclamation marks with the versions below. First of all,
global $IP, $wgMessageCache, $wgHooks;
global $IP, $wgMessageCache, $wgHooks, $wgSpecialInterwikiMessages;
And second, the entire block of $wgMessageCache->addMessage calls get replaced by:
require_once( 'SpecialInterwiki.i18n.php');
foreach( $wgSpecialInterwikiMessages as $key => $value ) {
$wgMessageCache->addMessages( $wgSpecialInterwikiMessages[$key], $key );}
Hope this helps. :) (Assuming you still need help with this, but if not, well, maybe the next person who's got the same problem will find this useful.) -- Schneelocke 17:33, 10 October 2007 (UTC)
This works. Thanks! SPQRobin 15:46, 12 October 2007 (UTC)


Here's a few things I'd suggest for this extension - any thoughts?

  • The warning message for empty interwiki tables should use the message cache.
  • The i18n patch should be integrated into the file.
  • The "add" form for new interwiki prefixes needs to be de-uglified.
  • The "add successful" message should present the interwiki table again for further edits (having to go back in your browser is annoying and breaks your workflow).

-- Schneelocke 17:41, 10 October 2007 (UTC)

I agree with you, except the i18n file should stay separately from the main file, but it should be mentioned in the main file by default (so there aren't problems like mine above :p). SPQRobin 15:46, 12 October 2007 (UTC)
I now changed the file so that it uses the i18n file by default (no need to patch). --MF-Warburg 08:09, 13 October 2007 (UTC)
Oh, yes, I agree, the i18n stuff should stay in a separate file. -- Schneelocke 19:40, 13 October 2007 (UTC)
I have "de-uglified" the add and delete form. I hope everyone finds it good :-) SPQRobin 15:09, 14 November 2007 (UTC)


I think I have found a bug:

  • First, I go to the form to add a new prefix, e.g. 'mw' for http://www.mediawiki.org/, and I click on "local"
  • Then I see in the log and in the recent changes: (Added "mw" (http://www.mediawiki.org/wiki/$1) (local: 0) (trans: 1) to the interwiki table)
  • I was thinking "Maybe I clicked on 'trans' instead of 'local'?" But no, when I go to Special:Interwiki, I see in the table "local: 1" and "trans: 0"

Strange... SPQRobin 14:09, 13 October 2007 (UTC)

We can just change the message
'interwiki_log_added' => 'Added "$1" ($2) (local: $3) (trans: $4) to the interwiki table: $5',
'interwiki_log_added' => 'Added "$1" ($2) (trans: $3) (local: $4) to the interwiki table: $5',
but I'm not sure this would be the right solution. SPQRobin 14:42, 13 October 2007 (UTC)
I looked to the source code and that is indeed the mistake. I've changed it. SPQRobin 18:17, 18 October 2007 (UTC)

Wrong Language

I installed this, it works, but I have to do some guessing work. Instead of English, is shows up as

Просмотр и изменение префиксов интервики

Nothing shows up as English. IS there a way to change it? 21:48, 18 October 2007 (UTC)

Never mind, It's been fixed. I replaced
$wgMessageCache->addMessages( $wgSpecialInterwikiMessages[$key], $key );}


$wgMessageCache->addMessages( $wgSpecialInterwikiMessages[en], $key );} 22:35, 18 October 2007 (UTC)

Couple of bugs?

The page wasn't showing up in Special:Specialpages, so I changed the line 46 from

SpecialPage::SpecialPage( 'Interwiki' );


SpecialPage::SpecialPage( 'Interwiki', 'interwiki' );

Was there any reason this wasn't done like this anyway?

Also, I was getting PHP errors about undefined variable out in lines 91 and 219. Obviously some paths through the function don't define this variable. To fix, I changed line 66:

if ($do == "delete") {


$out = '';
if ($do == "delete") { 09:44, 23 November 2007 (UTC)

Which version of MediaWiki do you use? I use the latest version and it works fine. SPQRobin 16:07, 23 November 2007 (UTC)
Mediawiki 1.11 (and php 5.2.4). Do you mean the Special page shows up fine, or you don't get php errors? The latter will definitely happen through certain paths ($do = delete, delete2 and add2). Just to be clear, even though the page didn't show in Special:Specialpages, I could still access it at Special:Interwiki ok. My LocalSettings.php contains the lines below and I'm in the sysop group. 23:58, 23 November 2007 (UTC)
$wgGroupPermissions['*']['interwiki'] = false;
$wgGroupPermissions['sysop']['interwiki'] = true;
Everything works fine on my testwiki. Do you use the latest version of SVN? SPQRobin 12:35, 24 November 2007 (UTC)

Yes, the latest version. To reproduce the undefined variable problem:

  1. Go to Special:Interwiki.
  2. Click delete on any entry (you don't need to confirm the deletion).
  3. View your webserver error log (apache 2.2.4 in my case) and there will be an entry saying something like

PHP Notice: Undefined variable: out in C:\\apache\\htdocs\\w\\extensions\\Interwiki\\SpecialInterwiki.php on line 91, referer: http://localhost/wiki/Special:Interwiki

If this doesn't produce an error, I guess your webserver must be different.

To reproduce the other problem:

  1. Using latest version of extension in SVN, on MW v1.11.
  2. Add the following lines to LocalSettings.php
$wgGroupPermissions['*']['interwiki'] = false;
$wgGroupPermissions['sysop']['interwiki'] = true;
  1. Log in as a user with sysop (and beaurocrat) rights.
  2. Go to Special:Specialpages and there is no entry for Interwiki.

If this does work for you, I can only assume you have some different entries for your wgGroupPermissions and/or you are using a user account with different permissions

FIXED Undefined Variable ('out' on line 195)

FIXED version 2008-01-11

Notice: Undefined variable: out in /home/bzc/public_html/wiki/extensions/Interwiki/SpecialInterwiki.php on line 195

I get this eror at the top of the page and it makes the rest of the fonts on the page look bad too. (Side effect of any error message I think)

Hi. Can you please provide some more information? Which version of MediaWiki? Which version/date of the Interwiki extension? Greetings, SPQRobin 22:09, 8 January 2008 (UTC)
Oh yes. SpecialInterwiki (version 14-12-07) on MediaWiki (version 1.11.0 ). Do I have to turn globals on or something? Version Page
I have set up a wiki with version 1.11.0rc1 and SpecialInterwiki version 14-12-07 but I hadn't any error. Also, on line 195 there is nothing what could cause an error. Did you change anything in the file? SPQRobin 16:58, 10 January 2008 (UTC)
I have made no modifications. I just upload the extensions and throw em in LocalSettings.php. The only customization is the cloning of the standard theme for my CSS and template modifications. I occasionally get a radom error of similar nature from a youtube extension on pages it isn't even used on. As soon as I figure out how, I will turn globals on and see if it fixes it. Since it is a warning about an undefining variable, it may be that the variable WAS defined as global and because of my current settings cannot be accesed. I guess I should start signing... - 21:23, 10 January 2008 (UTC)
Resolved in a recent commit. Siebrand 12:07, 11 January 2008 (UTC)
I'm sory, I'm new to this. "commit"? -- 07:27, 13 January 2008 (UTC)
If you are using MediaWiki 1.11 or later, please update your extension code from the download location that is noted on the extension page. Cheers! Siebrand 08:54, 13 January 2008 (UTC)
A "commit" is, in this case, an update to the code in the Wikimedia Foundation repository. On other projects, a commit refers to a change to the code in Subversion (SVN), which is the "official" copy, usually. All patches (changes) are generally made against the latest commit, or version, in SVN. But I go into too much detail... :D Tuvok[Talk/en.wp] 08:59, 13 January 2008 (UTC)
That's what I thought, but I must have downloaded it again before it was updated. I got it again, its working this time. I felt I should relabe the header for this part as FIXED and be more specific on the error for it to. Now I have to find out why some of my other mods have similar errors. Thanks again.-- 11:46, 13 January 2008 (UTC)

what does the local and trans checks mean on the special page?

what does the local and trans checks mean on the special page? --Emesee 09:27, 30 January 2008 (UTC)

'local' tells MediaWiki that it can redirect to that page if the link is included in either a #REDIRECT statement or is typed into the URL (compare Wikipedia's possibility to do things like w:en:fr:Accueil, which sends you to fr.wikipedia.org). 'trans' means you can transclude from that wiki if $wgEnableScaryTranscluding is enabled. For more info, take a look at Manual:Interwiki table. Tuvok[Talk/en.wp] 18:07, 30 January 2008 (UTC)

Version number please

It would be helpful if the developers of this extension assigned a version number to this extension. This could be in both the code (so it shows up in special:version) and the {{extension}} infobox on this extension page. This way at a glance we can know if our MediaWiki installations are up to to date. --Maxelrod 22:08, 25 February 2008 (UTC)

Code contains 'version' => '2008-01-11', Siebrand 00:03, 26 February 2008 (UTC)

How to "manipulate" the interwiki table ?

The description says : "Adds a special page to view and manipulate the interwiki table." I suppose I can change the table right from this special page, but can I do that ? There are no "modify" options or anything letting me work on it, is there ?

You have to be a user in the "sysop" (administrator) group to be able to "manipulate" (edit/modify) the interwiki table. SPQRobin 12:01, 24 July 2008 (UTC)
I am Sysop, and definitly have to "manipulate" this through PhpMyAdmin. The special page only let me see the changes...--NewMorning 12:19, 24 July 2008 (UTC)
Is your wiki on the internet so I could take a look at it? SPQRobin 12:30, 24 July 2008 (UTC)
You can see the same as I do as a sysop folowing this link (most pages locked) --NewMorning 12:49, 24 July 2008 (UTC)
Ah, I found the problem. You need to explicitly include the user right line in LocalSettings:
$wgGroupPermissions['sysop']['interwiki'] = true;
I thought it was by default. SPQRobin 13:12, 24 July 2008 (UTC)
YES, that was the point ! I might not be by default on a "secured" wiki... I'm fixed anyway, many thanks !

interlanguage links

I have no idea how the interlanguage links work and I was wondering if it is possible to have completely different sites appear in the language section of the side bar. ex if a page on my site is at 123wiki.com/foo is it possible to have a language link that goes to asdf.com/foo? Thanks for any help you can give me on this I'm really confused.

1.13 error

Fatal error: Call to undefined method SkinMonoBook::link() in SpecialInterwiki_body.php on line 222

Select the 1.13 version of the extension from the extension distributor. —Emufarmers(T|C) 15:33, 22 January 2009 (UTC)

Problem with MW 1.14

I downloaded the 2 files, version 14-12-07, and I see the following:

Fatal error: Call to undefined method Interwiki::fetch() in /usr/local/apache-2.2.8/htdocs/mediawiki/includes/Title.php on line 678
I had the same experience. I could fix it with downloading the version 1.12 (three files), replacing the two existing files in the according extensions directory. Everything seems to be fine then. *wave* --Rob -- 00:20, 26 March 2009 (UTC)

Rob, that fixed it, thank you. In retrospect I should have downloaded the most recent files, my mistake.

Where is the edit button so I can edit it.



Sachein 15:00, 8 April 2009 (UTC)

I have an interwiki privilege set, not sure if you need to do that also.

Capital letters in Prefixes

Take care not to use capital letters in prefixes when defining prefixes. I tried on my local mediawiki to add wikipediaDE which did not work, while wikipediade works fine. After defining wikipediade you can use the wiki tag [[wikipediaDE: ....]] and that will work!

Maybe this info could / should be added in the top line of the used Special:Interwiki&action=add in SpecialInterwiki.i18n.php!

Error 404, not found, unknown location

Yeah, I tried to download for my local MW1.6 but instead of files, I got HTTP 404 error :/ c'mon, I know that version 1.6 is old, but it's not the reason to make from people who want to dl files stupid fools! I can't also download files for another versions as well! What's the reason??? ~AnonymousR

Corrected info for LocalSettings.php

LocalSettings.php is configured one way for newer versions, and a different way for older versions. I updated the instructions, but someone might need to fix my formatting.

Log location?

What if using wikifamily, share interwiki table and want to have log location at the same place like shared interwiki table (for example en.wiki.com)? And links "log of changes" and "Add an interwiki prefix" should point to that one too. How to deal with it clean way?

Sites using this extension

I restored then cleaned up the list of sites which use this extension.


As of 12/12/2010 all of these sites are working and the extensions are working, giving editors many examples. Adamtheclown 11:21, 12 December 2010 (UTC)

"Download snapshot" gives old version

When I use the "Download snapshot" link in the sidebar, I get an old version of the extension, that still uses the "SpecialInterwiki"-Files. Why is that, and how is this to be fixed? --Olenz 09:00, 26 January 2011 (UTC)

No replacement bug

In web interface I get this kind of message: <interwiki> instead text.

Dificult to explain, just see: http://pool.blogxpopuli.org/wiki/Special:Interwiki

I'm using Mediawiki 1.14.0 with latest version of extension from subversion 81075. Thanks. --Ál 00:51, 27 January 2011 (UTC)

Local x Trans

What are these variables about?--Juan de Vojníkov 16:04, 16 March 2011 (UTC)

I think this question is the same as this other one. --Lance E Sloan 16:42, 16 March 2011 (UTC)

Download links to 1.4.1 version

Are the links to 1.4.1 version of extension correct? According to the version information from that files they are corresponded to 1.3 version. 19:34, 19 July 2011 (UTC)

In the file there is "1.3" which was outdated, but also "1.4.1" in the ExtensionCredits (the correct number). In any case, all versions below 2.0 should work. SPQRobin 20:10, 19 July 2011 (UTC)
ok, thanks. however it dosen't work with 1.17.0 (upgraded from 1.16.2): enabling of the extension in LocalSetting.php file results in blank pages instead of wiki.. 15:52, 20 July 2011 (UTC)
Strange, it works for me. Do you have a link to the wiki? Have you tried setting error_reporting(E_ALL); to see what's wrong? SPQRobin 16:27, 20 July 2011 (UTC)
Finally I found the reason of my problem: after "installing" by copy-paste some language information from Interwiki.i18n.php file was lost causing the trouble. 17:45, 20 July 2011 (UTC)

doesn't work in MW1.16.5

I've installed SpecialInterwiki from this link (1.16 → 1.18) and got an error: "Fatal error: Call to undefined function wfUILang() in /home/.../wiki/extensions/Interwiki/Interwiki_body.php on line 262" --Das steinerne Herz 04:27, 23 August 2011 (UTC)

Sorry, I forgot about that. I have corrected the link to the version for 1.16. Thanks, SPQRobin 10:51, 23 August 2011 (UTC)

Class 'LogFormatter' not found

I am getting the following error when installing Interwiki extension in my MediaWiki 1.16.4 (updated via One Click Install in DreamHost). I am using Interwiki 1.4.0

Fatal error: Class 'LogFormatter' not found in <mypath>/extensions/Interwiki/Interwiki_body.php on line 324

I haven't find a symilar error, so it seems this is happening to just me. Where can I find an dependency tree for this extension?

Chlewey 20:23, 21 October 2011 (UTC)

LogFormatter seems to be a quite new class in the MediaWiki core code (see [1], it exists since about 6 weeks). (BTW: You can find out such things by googling for "logformatter mediawiki" and following the links to websvn ;-)

Use an older version of the Interwiki extension that does not require this class yet. The easiest way is:

svn checkout http://svn.wikimedia.org/svnroot/mediawiki/branches/REL1_16/extensions/Interwiki

--Cboltz 20:48, 21 October 2011 (UTC)

Interwiki 1.4.0 is a version without code for LogFormatter. The problem is that the first download link points to the newest version of the file, which I tried to clarify now. SPQRobin 21:27, 1 December 2011 (UTC)

Main page replaced with Interwiki log!

This must be the strangest. I am totally new to mediawiki. this is my first attempt at extension installation.

I thought I followed your instructions. The bottom of my LocalSettings.php now looks like this:

# End of automatically generated settings.
# Add more configuration options below.


$wgGroupPermissions['*']['interwiki'] = false;
$wgGroupPermissions['interwiki']['interwiki'] = true;

$wgEnableScaryTranscluding = true;

$wgInterwikiMagic = true;
$wgHideInterlanguageLinks = false;

But now the main page of my wiki has been replaced with Interwiki's log! See here: http://fa.irfanpedia.org/

Has this happened to any one before? I must've done something really stupid but can't figure out what.

  • Which version of MediaWiki do you have?
  • If you navigate to your wiki via ftp or ssh and go to extensions/ is there an Interwiki folder in there with all its parts? If yes, what? Did you just upgrade? Do you have any other extensions installed?
  • You might try disabling the two lines related to interlanguage links and see if it works then.
  • If you have the extension in your wiki extensions/ directory, can you try revert your Local Settings so others can see what it used to look like?--Doug 21:22, 29 November 2011 (UTC)

You have downloaded and stored the version history as extensions/Interwiki/Interwiki.php. Please delete it ;-) and also check the other files in the directory - if they have similar content, also delete them.

Then download the correct files ;-)

  • go to http://svn.wikimedia.org/.... (see link in the extension page, depends on your mediawiki version)
  • for each file you need to re-download:
    • click the filename (for example "Interwiki.php")
    • click the "Download" link next to the first line starting with "Revision"
    • you now get the "real" file - store it in extensions/Interwiki/

--Cboltz 00:39, 30 November 2011 (UTC)

Cboltz and Doug: Thank you so much for your help. It was delightful to get not one but two immediate replies. Problem was exactly what Cboltz wrote. I feel both stupid and glad - glad because in the Drupal world, where I hang out, I had forgotten how difficult and confusing for a newcomer can be. It's easy to look down on newcomers who can't figure out what seems obvious to me. But now I feel totally ignorant once again because mediawiki is so different and I have to start from zero. --Ali.T 1:31 AM Dec 1, 2011 Iran Standard Time. By the way, is there a shortcut for having the system drop in your name and dateline or do you have to write it out by hand each time?

Use the "signature and timestamp" button above the edit area. It will add the code --~~~~ which expands to (in my case) --Cboltz 23:16, 30 November 2011 (UTC)

Transclusion not working

MW: 1.17 Ext: 1.4.1

I installed your extension. I am able to use the linking process without any problem. The transclusion is another story.

When I add {{Wikipedia:Welcome}} to my talk page, it does not place the template into the page. All I see is {{Wikipedia:Welcome}}

I did add this to my LocalSettings.php:

   $wgGroupPermissions['*']['interwiki'] = false;
   $wgGroupPermissions['sysop']['interwiki'] = true;
   $wgEnableScaryTranscluding = true;

What am I doing wrong that causes the text to not parse properly.

Make sure you have set the "transclusion" flag for that particular interwiki prefix. Note that this extension only shows which interwiki links are availabe and lets you edit them. It does not provide the code for actually transcluding pages. That is experimental core code (see Manual:$wgEnableScaryTranscluding for more info on that). Regards, SPQRobin 21:21, 1 December 2011 (UTC)

Why an error message for empty tables?

Hi - this extension is quite useful, but the message it displays if the interwiki DB table is empty seems weird, in my opinion: a red text that reads, "Error: The interwiki table is empty, or something else went wrong." Is having an empty table really an indication of error? Yaron Koren 05:50, 8 December 2011 (UTC)

It would be uncommon for a wiki to have no interwikis at all, so it's usually because something went wrong. But what would you show instead? Just drop the word "error"? In any case, this text is there since the extension was first written in 2005, so it's there just because it has always been there :) SPQRobin 12:34, 10 December 2011 (UTC)
I would either display nothing, or change the text to read just "The interwiki table is empty". Yaron Koren 22:48, 15 December 2011 (UTC)
Agreed that it should merely say "The interwiki table is empty." I recall SpecialNamespaces (which is a blatant rip-off of this extension, but recoded to create $wgExtraNamespaces instead of interwiki links) already contains such a change as the default MW installation is shipped with Wikimedia's interwiki table but with no extra namespaces as its initial state. Even then, WP's choices of which wikis are in the table are arbitrary - long-established sites are more likely to be there than newer sites, wiki farms are more likely to be there than independents, wikis with similar aims to WP are more likely there than parody wikis. As such, it's conceivable that a site owner may want to drop the entire default list and start anew, beginning with "The interwiki table is empty" and manually adding wikis similar in purpose or audience to the wiki on which this is being installed. This is not an error per se. --Carlb (talk) 19:14, 16 February 2012 (UTC)

Internal Server Error

Hey Guys,

can anyone help me to fix my problem:bugzilla:33169 also http://www.familienfreund.de/wiki/Spezial:Spezialseiten doesn't work

Thanks. --Kujawa0708 17:06, 15 December 2011 (UTC)

Please look at the version numbers under Extension:Interwiki#Download. You have MW 1.18 and Interwiki 2.0, but 1.4.1 should be used on 1.18. SPQRobin 11:37, 18 December 2011 (UTC)

Getting Login Screen when Transcluding

Hello, I'm having problems transcluding content from one wiki to another. When I try transcluding a page from a different wiki all I see is the login page with my toolbar content embedded on the page. I have my permissions set up like this:

        $wgGroupPermissions['*']['read'] = false;
	$wgGroupPermissions['*']['edit'] = false;
	$wgGroupPermissions['*']['interwiki'] = true;

From what I've read, transclusion should work based on these permissions and setting $wgEnableScaryTranscluding to true with the above permissions. I'm calling the transcluded page like so: {{ iw_prefix::target }} after inserting my prefix into the interwiki table and setting iw_trans to 1. I can transclude public pages that are whitelisted in my LocalSettings.php, but any other page from my wiki cannot transclude. I need to keep my read and edit permissions the same since we only allow logged in users to see and add content. I'm running MediaWiki 1.16.5.

Thanks in advance!!--Jhunter13 (talk) 19:02, 29 February 2012 (UTC)

Doesn't show up on Sturmkrieg Special:Version

For some reason this isn't showing up on the Sturmkrieg Special:Version. I'm not sure why. Someone pointed this out on the Pages using this extension page. Inquisitor_Ehrenstein (Inquisitor_Ehrenstein) 07:16, 28 March 2012 (UTC)

I can see it on Special:Version, the last one in the "special pages" section. Regards, SPQRobin (talk) 17:59, 28 March 2012 (UTC)

Move to Git?

You can use Git/Conversion/Extensions queue to request a move to Git, which you would need to do in order for this to be deployed to WMF wikis. Thanks! Sumana Harihareswara, Wikimedia Foundation Volunteer Development Coordinator (talk) 14:03, 4 April 2012 (UTC)

Thanks, I added it there now. SPQRobin (talk) 20:52, 7 April 2012 (UTC)
And now it's on WMF wikis: -- https://blog.wikimedia.org/2012/05/29/wikimedia-wikis-reveal-interwiki-map/ Sumana Harihareswara, Wikimedia Foundation Engineering Community Manager (talk) 20:56, 29 May 2012 (UTC)

Session problem when adding new entry

Hi. Everytime I add a new interwiki entry, the extension returns this error: "There seems to be a problem with your login session; this action has been canceled as a precaution against session hijacking." I can edit/update existing entries fine, no errors at all. I can login (obviously), update preferences, edit pages. PHP session and /tmp is also working (since I can login and do everything else). The only thing I can not do for some reason is to add a new interwiki entry via Special:InterWiki What did I miss? Laibcoms (talk) 07:24, 10 April 2012 (UTC)

interwiki cache

If the interwiki cache is used (probably only the case on WMF wikis), Special:Interwiki only shows them and cannot be used to edit them. See the bug. SPQRobin (talk) 19:25, 25 May 2012 (UTC) You're right, the extension should/could clear the (memcached) cache for a deleted prefix; see my other comment on the bug :-) SPQRobin (talk) 22:34, 25 May 2012 (UTC)
I have to change my comment again: apparently the extension removes the prefix in memcached too since r114912 (so essentially doing the same as clear_interwiki_cache.php). SPQRobin (talk) 00:05, 26 May 2012 (UTC)


Tele123 (talk) 12:13, 13 August 2012 (UTC) I have problem with Interwiki 1.19+ on MediaWiki 1.19.1 .

1. Parse error: syntax error, unexpected $end in /virtual/p/c/........../LocalSettings.php on line 169

Solved: In the end file LocalSettings.php not exist " ?> " corect file build is for example:


# comment


2. Warning: require_once(/virtual/p/c/....../extensions/Interwiki/Interwiki.php) [function.require-once]: failed to open stream: No such file or directory in /virtual/p/c/....../LocalSettings.php on line 159

Fatal error: require_once() [function.require]: Failed opening required '/virtual/p/c/......../extensions/Interwiki/Interwiki.php' (include_path='.:/usr/share/php:/usr/share/pear5.2') in /virtual/p/c/........../LocalSettings.php on line 159

Folder Interwiki when you extract/unzip/unpack have name "Interwiki-master-7504ab3" the correct name is "Interwiki", you can rename folder name , before you put this in extension folder.

How Interwiki works?

How Interwiki works?

I have website example: http://www.kkj.com

I need build new websites with, example " en " and other for other language? Like http://www.en.kkj.com ?

Example link: [[en:mainpage]]

Can I build websites like this: http://www.kkj.com/en/ ?

If yes, how can I do this? How builds links interwiki?

How I can add other language to sidebar?

How can I add other language to sidebar?

See the section "Setting up interlanguage links" on Extension:Interwiki. SPQRobin (talk) 14:31, 14 August 2012 (UTC)

Great !

I would like to thanx the dev(s) for the new "highlighted yes" cells in the interwiki overview, this is a great addition.
Mlpearc (powwow) 16:55, 7 November 2012 (UTC)


What do you think of the idea of merging Extension:InterwikiMap into this extension? It might be helpful to have an option on Special:Interwiki to download an interwiki list from a remote wiki, and to set it up to poll that wiki from time to time for updates. Leucosticte (talk) 07:47, 20 November 2012 (UTC)

What to download?

What to download? There are 16 "snapshot" links and more?!

Copy and install all these files into a newly created directory named Interwiki at this location: your wiki/w/extensions/. Then continue to follow these instructions. Mlpearc (powwow) 19:50, 13 January 2013 (UTC)


I am running MediaWiki 1.22.3 in Chinese. When I open Special:Interwiki, I get the following message: [184cf32a] 2014-03-07 06:36:53: Fatal exception of type MWException

What did I do wrong in the installation? - Vincent Liu (talk) 06:40, 7 March 2014 (UTC)

I have the same problem with a MediaWiki 1.22.3 in german language on a Windows 7 system witch XAMPP. The extension came together with the MediaWiki installation, and I got the settings for the LocalSettings.php from here. -- 20:27, 21 March 2014 (UTC)

Error 404 [Resolved]

When trying to add an interwiki prefix to my Norwegian website I get: HTTP Error 404.0 - Not Found The resource you are looking for has been removed, had its name changed, or is temporarily unavailable. Requested URL: http://www.hattebol.no:80/Spesial:Interwiki/add/ Physical Path: C:\inetpub\wwwroot\OlePedia\Spesial:Interwiki\add\

Website: www.hattebol.no MediaWiki 1.22.5 PHP 5.4.26 (cgi-fcgi) MySQL 5.6.17 Lua 5.1.4

Help would be appreciated. OlePedia (talk)

It was an error in the rewrite script. I had followed the manual: http://www.mediawiki.org/wiki/Manual:Short_URL/wiki/Page_title_--_Windows_with_IIS7--root_access which created a complicated script and didn't work. The link on the page to http://shorturls.redwerks.org/ however, created a working rewrite script.

Thanks to SPQRobin (Robin Pepermans) who pointed me in the right direction. OlePedia (talk)


The infobox has 3.0, Interwiki.php says 2.2, my freshly updated farm says 2.3 ? Thanx, Mlpearc (open channel) 22:53, 26 September 2014 (UTC)

I confirm last version in master is 3.0 20140719. You see different numbers, great, so you know you have different code. Version bump success! --Nemo 06:25, 27 September 2014 (UTC)
lol. OK, I guess. I'll just update adjust Interwiki.php on my project using the master and not the stable version :P Mlpearc (open channel) 16:07, 27 September 2014 (UTC)

Typo in french special page

Before the language table, the french wikipedia's Spécial:Interwiki shows :

Préfixes interlangues
Ces préfixes correspondent à des codes de langue défini et sont utilisés pour créer la liste "Autres langues" lorsqu’ils sont ajoutés à une page.

Should be : codes de langue définis (just need to add the "s" after "défini").

Thanks to correct it and install the correction wherever appropriate. --SGlad (talk) 17:49, 28 November 2014 (UTC)

Problems Adding New Interwiki Prefix [Resolved]

Hi All,

Wonder if someone can help? I'm trying to set up a new interwiki link, but I'm getting the following error message: "Prefix could not be added to the interwiki table. Possibly it already exists in the interwiki table." (It isn't!)

Interestingly, I've tried adding the link directly to the database. It lets me add it there, and it appears in the list, but the wiki just doesn't recognise the prefix.

Any ideas what I could be missing? I'm a sysops, and the interwiki permission has been granted.


Fix Found

--Dshinks (talk) 10:56, 10 June 2016 (UTC)

I've worked out what was wrong in my case; this might help anyone else having similar difficulties. (N.B. this is fixed for my instance running 1.26.2 running on a SQLite Database)
It appears that the version of the Interwiki table in my database has a couple of extra columns that the Interwiki plugin doesn't include in its update statement:
  • iw_api
  • iw_wikiid
Existing entries in this table have blank values in these fields.
Steps to Fix
Changes required to file Interwiki_body.php
In the function doSubmit(),
Update this section:
		case 'add':
			$prefix = $wgContLang->lc( $prefix );
			// N.B.: no break!
		case 'edit':
			$theurl = $request->getVal( 'wpInterwikiURL' );
			$local = $request->getCheck( 'wpInterwikiLocal' ) ? 1 : 0;
			$trans = $request->getCheck( 'wpInterwikiTrans' ) ? 1 : 0;
			$data = array(
				'iw_prefix' => $prefix,
				'iw_url' => $theurl,
				'iw_local' => $local,
				'iw_trans' => $trans
		case 'add':
			$prefix = $wgContLang->lc( $prefix );
			// N.B.: no break!
		case 'edit':
			$theurl = $request->getVal( 'wpInterwikiURL' );
			$local = $request->getCheck( 'wpInterwikiLocal' ) ? 1 : 0;
			$trans = $request->getCheck( 'wpInterwikiTrans' ) ? 1 : 0;
			$data = array(
				'iw_prefix' => $prefix,
				'iw_url' => $theurl,
				'iw_local' => $local,
				'iw_trans' => $trans,
				'iw_api' => '',
				'iw_wikiid' => ''

Automatic authentication for local wiki transcludes

Intention is to transclude pages of other wiki

Looking for a means to authenticate an interwiki shortcut automatically, Any alternative method short of replicating the other wiki is also of interest. Currently investigating possibility mentioned in a concept document for direct access to other wiki mysql tables

So far, I have failed to find anything to suggest a means to allow me to transclude. WGET on the local wiki simply redirects me to the login page. 'Other wiki' is MediaWiki 1.24.2 PHP 5.3.3 (apache2handler) MySQL 5.1.73 Elasticsearch 1.7.2

Local wiki is: MediaWiki 1.24.1 PHP 5.6.3 (apache2handler) MySQL 5.6.21


There is not, to my eyes, any information on how to actually use the Interwiki extension. Could this be fixed, please? Calion (talk) 15:44, 7 February 2018 (UTC)

There it is: https://www.mediawiki.org/wiki/Help:Links#Interwiki_links. Could that be inserted into this page somewhere, please? Calion (talk) 23:30, 7 February 2018 (UTC)
I'm not sure where to report this, but Special:Interwiki on installed MediaWiki 1.30 says "For recommended use, please see the manual on MediaWiki.org," but directs to this page, which says nothing about recommended use. The correct link is https://www.mediawiki.org/wiki/Manual:Interwiki.

Edit interwiki table through API

Is there a an API method to edit the interwiki table? It looks like the siteinfo query only allows viewing the current table. --pcj (talk) 15:03, 13 June 2018 (UTC)


Why is there no IRCS in Special:Interwiki? IRCS should be preferred over IRC, 'cause its secure. All Template:Channel transclusions are linking to insecure connections. Thanks --Ptolusque (talk) 08:51, 22 July 2018 (UTC)

Note Note: task T200151 --Ptolusque (talk) 09:17, 22 July 2018 (UTC)