Open main menu

MediaWiki β

Project:Support desk

About this board

vde   Welcome to's Support desk, where you can ask MediaWiki questions!

There are also other places where to askCommunication: IRCCommunication#Chat, mailing listsMailing lists, Q&A etc.

Before you post

Post a new question

  1. To help us answer your questions, please always indicate which versions you are using (reported by your wiki's Special:Version page):
    • MediaWiki
    • PHP
    • Database
  2. Please include the URL of your wiki unless you absolutely can't. It's often a lot easier for us to identify the source of the problem if we can look for ourselves.
  3. To start a new thread, click "Start a new topic".
By clicking "Add topic", you agree to our Terms of Use and agree to irrevocably release your text under the CC BY-SA 3.0 License and GFDL

[RESOLVED] After Update Error: 1054 Unknown column 'ug_expiry' in 'field list' (localhost)

Nelodie (talkcontribs)


After a upgrade of Ubuntu ( to 16.04) My dear wiki developped on mediawiki 1.23 was not work. After some search on web, I decided to update also mediawiki to last version 1.29 by following all instructions described in Update manuel.

So basicaly, I dump my DB, save in tar.gz files before download the mediawiki-1.29.1.tar.gz.

After all my images folder was copied and extensions are updated I run also the update.php script wiith no error.

The first run my wiki home page I obtain just a error about "wfLoadSkin( 'Vector' );" forgotten. So I modified correctly the LocalSettings.php file and run again the home page of my wiki... but I have this SQL error 

6e1e893ddacaf2198378f128] /wiki/index.php/Accueil Wikimedia\Rdbms\DBQueryError from line 1075 of /var/lib/mediawiki/includes/libs/rdbms/database/Database.php: A database query error has occurred. Did you forget to run your application's database schema updater after upgrading? 

Query: SELECT ug_user,ug_group,ug_expiry FROM `user_groups` WHERE ug_user = '31' 

Function: UserGroupMembership::getMembershipsForUser

Error: 1054 Unknown column 'ug_expiry' in 'field list' (localhost)

I was tried to update manually the DB by dump but the error stay.

Could you help me ? 

Produit Version
MediaWiki 1.29.1
PHP 7.0.22-0ubuntu0.16.04.1 (apache2handler)
MySQL 5.7.19-0ubuntu0.16.04.1


Osnard (talkcontribs)

Looks like update.php did not apply for whatever reason. You can apply the patch manually. Just make sure to replace /*$wgDBprefix*/ with your configured database prefix (defined in LocalSetting.php)

Nelodie (talkcontribs)

Thanks you very much @Osnard

I  applied manually your SQL Code and the wiki appeared and worked fine.


Andrewschlussel (talkcontribs)


I'm looking for the best way to create modular content. Basically embedding pages, or parts of pages in other pages.

I work at a company where we are using the wiki for training for many different departments.

I'm looking for ways to standarize the information and reduce duplication of effort.

I would like to have standard sets of training content that can be embedded in multiple pages. But that content would only need to be edited and maintained in one area and would automatically be updated in every instance where it is embedded.

What is the best way to do this with MediaWiki?


AhmadF.Cheema (talkcontribs)

See Transclusion and Extension:Labeled Section Transclusion.

Reply to "Embed modular content"

Error message after installing html2wiki extension

Summary by AhmadF.Cheema

Various issues...

Bigfoot c (talkcontribs)

Dear all,

I am charged with testing some features of mediaWiki. I am running a fresh install of mw 1.29 on an xamp-server (OS is Win10). Having installed the extension html2wiki according to the steps mentioned at Extension:Html2Wiki , I get the following error message, which I have been unable to decipher. I could not find a proper description on the web either, at least not in context with the extension in question. The error message reads as follows:

Warning:  call_user_func() expects parameter 1 to be a valid callback, class 'Html2Wiki' not found in C:\xampp\htdocs\mediawiki\includes\registration\ExtensionRegistry.php on line 335

Also note that I used GitBash for installing the extension (as suggested). I also added the following lines to my LocalSettings.php:


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

$wgNamespacesWithSubpages[NS_MAIN] = true;

wfLoadExtension( 'Html2Wiki' );

Would be great if somebody could point out what this error signfies. I have currently no idea how to resolve the issue. Thanks for all help provided, it is much appreciated

Kind regards


Osnard (talkcontribs)

How did you download this extension? By Special:ExtensionDistributor? Or by GIT?

Because if you used GIT, you will have to execute composer install [1]within the extension directory.


Bigfoot c (talkcontribs)

Dear Osnard,

Thank you for your reply. I downloaded the extension via git as suggested on the webpage. I added composer to my PATH env and ran composer install in the extension directory. Unfortunately, the error message still occurs when launching my wiki. Please refer to the code below for suggestions should I have made a mistake during installation. Please note, I am using WIN10 and XAMP (not by choice though :=) )

Microsoft Windows [Version 10.0.15063] c:\xampp\htdocs\mediawiki\extensions>composer install No composer.json in current directory, do you want to use the one at C:\xampp\htdocs\mediawiki? [Y,n]? y > ComposerHookHandler::onPreUpdate Loading composer repositories with package information Updating dependencies (including require-dev) Package operations: 38 installs, 1 update, 15 removals

 - Removing symfony/process (v3.2.6)
 - Removing james-heinrich/getid3 (v1.9.14)
 - Removing pear/net_socket (v1.1.0)
 - Removing pear/pear-core-minimal (v1.10.3)
 - Removing pimple/pimple (v3.0.2)
 - Removing pear/net_smtp (1.7.3)
 - Removing wikimedia/textcat (1.2.0)
 - Removing stil/gd-text (v1.0.0)
 - Removing firebase/php-jwt (v4.0.0)
 - Removing ruflin/elastica (5.1.0)
 - Removing pear/mail (1.3.0)
 - Removing pear/mail_mime-decode (
 - Removing pear/mail_mime (1.10.0)
 - Removing pear/console_getopt (v1.4.1)
 - Removing pear/pear_exception (v1.0.0)
 - Updating justinrainbow/json-schema (5.2.0 => 3.0.1): Downloading (100%)
 - Installing composer/spdx-licenses (1.1.4): Downloading (100%)
 - Installing jakub-onderka/php-parallel-lint (v0.9.2): Downloading (100%)
 - Installing jetbrains/phpstorm-stubs (dev-master 1b99060): Cloning 1b9906084d
   Failed to download jetbrains/phpstorm-stubs from source: Failed to clone, git was not found, check that it is installed and in your PATH env.
   Now trying to download from dist
 - Installing jetbrains/phpstorm-stubs (dev-master 1b99060): Downloading (100%)
 - Installing squizlabs/php_codesniffer (2.6.0): Downloading (100%)
 - Installing mediawiki/mediawiki-codesniffer (v0.7.2): Downloading (100%)
 - Installing symfony/yaml (v3.3.9): Downloading (100%)
 - Installing sebastian/version (1.0.6): Downloading (100%)
 - Installing sebastian/global-state (1.1.1): Downloading (100%)
 - Installing sebastian/recursion-context (1.0.5): Downloading (100%)
 - Installing sebastian/exporter (1.2.2): Downloading (100%)
 - Installing sebastian/environment (1.3.8): Downloading (100%)
 - Installing sebastian/diff (1.4.3): Downloading (100%)
 - Installing sebastian/comparator (1.2.4): Downloading (100%)
 - Installing doctrine/instantiator (1.1.0): Downloading (100%)
 - Installing phpunit/php-text-template (1.2.1): Downloading (100%)
 - Installing phpunit/phpunit-mock-objects (2.3.8): Downloading (100%)
 - Installing phpunit/php-timer (1.0.9): Downloading (100%)
 - Installing phpunit/php-file-iterator (1.4.2): Downloading (100%)
 - Installing phpunit/php-token-stream (1.4.11): Downloading (100%)
 - Installing phpunit/php-code-coverage (2.2.4): Downloading (100%)
 - Installing webmozart/assert (1.2.0): Downloading (100%)
 - Installing phpdocumentor/reflection-common (1.0.1): Downloading (100%)
 - Installing phpdocumentor/type-resolver (0.4.0): Downloading (100%)
 - Installing phpdocumentor/reflection-docblock (4.1.1): Downloading (100%)
 - Installing phpspec/prophecy (v1.7.2): Downloading (100%)
 - Installing phpunit/phpunit (4.8.35): Downloading (100%)
 - Installing jakub-onderka/php-console-color (0.1): Downloading (100%)
 - Installing jakub-onderka/php-console-highlighter (v0.3.2): Downloading (100%)
 - Installing dnoegel/php-xdg-base-dir (0.1): Downloading (100%)
 - Installing nikic/php-parser (v2.1.0): Downloading (100%)
 - Installing symfony/polyfill-mbstring (v1.5.0): Downloading (100%)
 - Installing symfony/var-dumper (v3.3.9): Downloading (100%)
 - Installing symfony/debug (v3.3.9): Downloading (100%)
 - Installing symfony/console (v3.3.9): Downloading (100%)
 - Installing psy/psysh (v0.8.5): Downloading (100%)
 - Installing wikimedia/testing-access-wrapper (1.0.0): Downloading (100%)
 - Installing hamcrest/hamcrest-php (v2.0.0): Downloading (100%)
 - Installing wmde/hamcrest-html-matchers (v0.1.1): Downloading (100%)

sebastian/global-state suggests installing ext-uopz (*) phpunit/phpunit-mock-objects suggests installing ext-soap (*) phpunit/php-code-coverage suggests installing ext-xdebug (>=2.2.1) phpunit/phpunit suggests installing phpunit/php-invoker (~1.1) symfony/var-dumper suggests installing ext-symfony_debug () symfony/console suggests installing symfony/event-dispatcher () symfony/console suggests installing symfony/filesystem () symfony/console suggests installing symfony/process () psy/psysh suggests installing ext-pcntl (Enabling the PCNTL extension makes PsySH a lot happier :)) psy/psysh suggests installing ext-posix (If you have PCNTL, you'll want the POSIX extension as well.) psy/psysh suggests installing ext-pdo-sqlite (The doc command requires SQLite to work.) psy/psysh suggests installing hoa/console (A pure PHP readline implementation. You'll want this if your PHP install doesn't already support readline or libedit.) Writing lock file Generating optimized autoload files c:\xampp\htdocs\mediawiki\extensions>

Am I right in the assumption that you would suggest removing the extension and trying to install it using the Extension Distributor? Please let me know if you could provide other hints about how to resolve the issues.

Thank you very much in advance for your support.

PS: Sorry for the formatting, I could not figure out why <code> did not display properly in this case. Help would be appreciated

Osnard (talkcontribs)

I've had a quick look at the source code. It looks like the master branch is not operational. The "Html2Wiki" class which provides the callback is not registered to the autoloader.

I'd suggest you try to download REL1_29 from Special:ExtensionDistributor.

Bigfoot c (talkcontribs)

Dear Osnard

Thanks a mil for your suggestions. I followed the instructions you kindly provided, but so far I have been unable to run my wiki after making the necessary changes to the LocalSettings.php. As described in the Html2Wiki documentation, I added the following lines to my LocalSettings.php and ran the composer afterwards.

$wgNamespacesWithSubpages[NS_MAIN] = true; wfLoadExtension( 'Html2Wiki' );

When launching the wiki on my localhost server, the following error message crops up. I had a look at those php code lines mentioned in the error messages, but could not figure out how to resolve the issue, since the information in question appears to be stored in a variable. I do lack the skills for properly debugging php, but I have the feeling that this will not be necessary, since I am afraid I have yet made another configuration / installation error. This is the error I got (when removing the lines above, the wiki works fine, hence my assumptions about the config/install error). I would be delighted if you or other people could provide some assistance.

Fatal error: Uncaught Exception: C:\xampp\htdocs\mediawiki/extensions/Html2Wiki/extension.json does not exist! in C:\xampp\htdocs\mediawiki\includes\registration\ExtensionRegistry.php:99 Stack trace: #0 C:\xampp\htdocs\mediawiki\includes\GlobalFunctions.php(118): ExtensionRegistry->queue('C:\\xampp\\htdocs...') #1 C:\xampp\htdocs\mediawiki\LocalSettings.php(139): wfLoadExtension('Html2Wiki') #2 C:\xampp\htdocs\mediawiki\includes\WebStart.php(127): require_once('C:\\xampp\\htdocs...') #3 C:\xampp\htdocs\mediawiki\index.php(40): require('C:\\xampp\\htdocs...') #4 {main} thrown in C:\xampp\htdocs\mediawiki\includes\registration\ExtensionRegistry.php on line 99

Thanks in advance for your time and suggestions.

AhmadF.Cheema (talkcontribs)

Replace wfLoadExtension( 'Html2Wiki' ); with

require_once "$IP/extensions/Html2Wiki/Html2Wiki.php";

(or C:\xampp\htdocs\mediawiki/extensions/Html2Wiki/Html2Wiki.php).

This should resolve one of the errors.

Using wfLoadExtension is the newer method of installing extensions, which required the extension files to have been updated with an extension.json file. For Html2Wiki it appears that only the master version has been updated and not the REL_1.29 branch. Therefore, when using REL_1.29 branch, the older method of activating extensions is required.

Bigfoot c (talkcontribs)

Dear AhmadF.Cheema, Thank your very much for your insight. I was able to resolve this particular issue with the help of your comments. However, I am now struggling with a new issue regarding the installation of this particular plugin. I am sorry for all these questions but I have not done any XAMP stuff on a WIN machine before. The next issue is that the Plugin seems to require Pandoc. I install Pandoc on my local machine and also added it ot the path environment. After restarting XAMP the error still appears saying

Html2Wiki requires pandoc.

On Ubuntu systems this is as simple as sudo apt-get install pandoc

Please see the installation instructions at for more info. Could anybody please tell me how to go about the installation of Pandoc on an XAMP / WIN10 System?

Thanks in advance for your comments. Kind regards C.

AhmadF.Cheema (talkcontribs)

To make sure that Pandoc is installed and set in PATH, does running pandoc --version in cmd, show the installed Pandoc version? Also, have you installed composer too.

Bigfoot c (talkcontribs)

Dear AhmadF.Cheema

Thanks a mil for your reply. I just wanted to get back to regarding your comments. Pandoc is installed C:\WINDOWS\system32>pandoc --version pandoc Compiled with pandoc-types, texmath 0.9, skylighting Default user data directory: C:\Users\creske\AppData\Roaming\pandoc Copyright (C) 2006-2016 John MacFarlane Web: This is free software; see the source for copying conditions. There is no warranty, not even for merchantability or fitness for a particular purpose I ran the composer installer again to make sure it is installed properly. During installation I set the following php executable C:\xampp\php\php.exe

After that I ran a test-import of a zip-file containing html-files that I had previously prepared. The import was successful. I guess it is working now, otherwise I'll get back to the forum.

Thank you so much for your support in this matter, it is much appreciated.

Kind regards C. (talkcontribs)

Where can i find the database?

Osnard (talkcontribs)

Configuration of the database can be found in the LocalSettings.php file. Search for variables "$wgDBtype", "$wgDBserver", "$wgDBname, "$wgDBuser", and "$wgDBpassword". With this information you should be able to connect to the database.

Reply to "How do i find the database?"

Failure to Upload files to MediaWiki

Steve0613 (talkcontribs)

Good morning, I am experiencing issues with uploading files to my MediaWiki v1.26.2 server. Our current setup is as follows:

PHP v5.4.16, MariaDB v5.5.47, Apache v2.4.6.40

I have enabled debugging and receive the following errors when attempting to upload:

[exception] [6476b2a0] /mediawiki/index.php/Special:Upload   MWException from line 1868 of /var/www/mediawiki-1.26.2/includes/filerepo/file/LocalFile.php: Could not acquire lock for 'Cable.JPG.'

G#0 /var/www/mediawiki-1.26.2/includes/filerepo/file/LocalFile.php(1147): LocalFile->lock()

#1 /var/www/mediawiki-1.26.2/includes/upload/UploadBase.php(708): LocalFile->upload(string, string, string, integer, array, boolean, User)

#2 /var/www/mediawiki-1.26.2/includes/specials/SpecialUpload.php(486): UploadBase->performUpload(string, string, boolean, User)

#3 /var/www/mediawiki-1.26.2/includes/specials/SpecialUpload.php(197): SpecialUpload->processUpload()

#4 /var/www/mediawiki-1.26.2/includes/specialpage/SpecialPage.php(384): SpecialUpload->execute(NULL)

#5 /var/www/mediawiki-1.26.2/includes/specialpage/SpecialPageFactory.php(553): SpecialPage->run(NULL)

#6 /var/www/mediawiki-1.26.2/includes/MediaWiki.php(281): SpecialPageFactory::executePath(Title, RequestContext)

#7 /var/www/mediawiki-1.26.2/includes/MediaWiki.php(714): MediaWiki->performRequest()

#8 /var/www/mediawiki-1.26.2/includes/MediaWiki.php(508): MediaWiki->main()

#9 /var/www/mediawiki-1.26.2/index.php(41): MediaWiki->run()

#10 {main}

DatabaseBase::query: Writes done: REPLACE INTO `msg_resource` (mr_resource,mr_lang,mr_blob,mr_timestamp) VALUES ('X')

OutputPage::sendCacheControl: no caching **

[error] [5a2ad114] [no req]   ErrorException from line 4262 of /var/www/mediawiki-1.26.2/includes/db/Database.php: PHP Notice: Uncommitted DB writes (transaction from DatabaseBase::query (User::loadFromDatabase)).

#0 [internal function]: MWExceptionHandler::handleError(integer, string, string, integer, array)

#1 /var/www/mediawiki-1.26.2/includes/db/Database.php(4262): trigger_error(string)

#2[internal function]: DatabaseBase->__destruct()

#3 {main}

NOTE: This server has worked fine since we set it up. Then out of the blue we couldn't upload files. We are in a production environment and need this thing fixed. Any assistance would be greatly appreciated. Thank you!

Ciencia Al Poder (talkcontribs)

I'd say something has changed in your server, this particular thing doesn't break on its own...

  • Verify permissions on the images folder
  • Verify if you have SELinux enabled, and disable it to test if some kind of additional enforcement was added
  • Check free space on the mount point where images are stored, just in case you ran out of space
Steve0613 (talkcontribs)

Figured out the issue pertains to the /var/www/html/mediawiki/images directory being sym-linked to a network share. Moved the images file from the file server to the local machine and this worked. Still need to figure out what was causing the issues with sym-links.


Parser functions won't register magic word

Corpubro (talkcontribs)

So I am following the code at and duplicated it exactly. But when I attempt to load my extension, I receive the following message:

/content/Special:Version MWException from line 336 of /var/www/html/wiki/includes/MagicWord.php: Error: invalid magic word 'example'

I'm guessing this may just be another example of documentation being out of date, but I began dissecting other extensions and find they use the exact same syntax and setup from what I can tell. I then thought maybe there was a magic word collision so I began trying out a series of increasingly bizarre combinations of letters but still the exact same error (only with the word "example" replaced, of course).

Any insight on what I am missing?

Again, I set up the project exactly as described at the top of

Corpubro (talkcontribs)

Digging deeper, for some reason mSynonyms has a length of 0 for the MagicWord I've registered. No other magic word has such a thing.

Corpubro (talkcontribs)

Further stepping back into MW's code, I'm finding the "example" magic word is not making it into the LocalisationCache. It was suggested elsewhere to run 'rebuildLocalisationCache.php --force' in order to rebuild the cache, and I had already done so in my prior troubleshooting efforts to no avail. I still don't understand where the disconnect is in preventing my magic word from being registered into the localisation cache. I guess the only answer is to continue to take apart the MW code to see where the breakdown is occurring. Unless anyone else has a shortcut to help out here?

Osnard (talkcontribs)

Do you have your code online in a public repository, so one could have a look?

Reply to "Parser functions won't register magic word"
Sabiya115 (talkcontribs)

i m having a requirement of using special pages for getting concatenated topics of all pages flow board. and for that i m trying using queries. but on the same page i need flow board widget to enter new topics.

How to apply flow like widget for special page. any help would be appreciable.

Malyacko (talkcontribs)

Flow is for structured discussions. Special pages are not discussion pages (in my understanding)?

Star Warden (talkcontribs)

Maybe they could work out something through the SpecialTalk extensions?

Sabiya115 (talkcontribs)

Special pages we can can use for our bilerplate code, i want to list all the topics of all talk pages concatenated on single special page via sql queries and want to have add topic widget above the topic list for adding new topic on special page???

How this could be achieved, any suggestions

Fokebox (talkcontribs)

There is a project: It aims to create a special page for Flow discussions so it makes like a forum for users and it will structure all topics. But now it is just an idea among volunteers, I hope it will be finally developed

Sabiya115 (talkcontribs)

This is exactly what i wanted, thankyou for your suggestion. i need to wait for it to get developed.

Hi - I would like to insert a photo on the Star Trek Main Frame game page.

Ken Jansen (talkcontribs)

I have 40+ year old print outs of the game to share

AhmadF.Cheema (talkcontribs)

Where exactly is this "Star Trek Main Frame game page"? If you meant the Star Trek (text game) Wikipedia page, then w:Wikipedia:Contributing to Wikipedia is the place to start.

However, if it appears to be too much information and you just want to quickly upload some non-controversial pictures, see w:Wikipedia:File Upload Wizard.

Reply to "Hi - I would like to insert a photo on the Star Trek Main Frame game page."
NostalgicColorBird (talkcontribs)

Are there any extensions that support private messaging?

Also, is there a list of recommended extensions?

AhmadF.Cheema (talkcontribs)

Might be possible through Extension:MediaWikiChat. The MediaWiki extensions aren't the most aesthetic or smooth. You can even try GosuChat implemented on this wiki., although I'm not sure whether private messages are possible at the moment or not.

Reply to "Private messaging"
2A01:C50E:896D:C100:30ED:1B34:A061:2149 (talkcontribs)

Hi everybody,

I am trying to install extensions of mediawiki but I do something wrong. For example, consider CentralNotice extension. I decompress the extension into /extension/CentralNotice directory, in LocalSetting.php I add require_once( "$IP/extensions/CentralNotice/CentralNotice.php" ); and what else I have to do? In which namespace do I have to enter? How can I now it for any arbitrary extension?

MarkAHershberger (talkcontribs)

When you say /extension/CentralNotice, I assume you mean /extensions/CentralNotice. (You left out "s".)

But, still, you asked "what else do I have to do" and didn't mention errors, so I assume you did that correctly.

Since you're asking about CentralNotice here, I'm also going to assume that you don't have multiple wikis. In this case, you should follow the instructions for all wikis and also for the infrastructure wiki. It sounds like you did the first, did you do the second?

There are also usage instructions. Did you follow those?

2A01:C50E:896D:C100:4508:FAC2:51CA:E3FF (talkcontribs)

The problem is not for CentralNotice extension. This is only an example. I would like (in general) how to activate an extension after installing. How can I know which name spaces they have created? How can I access to all configuration panels they create? Could you put me an entire example of extension (no matter which) of installing and then of using in order to reproduce it and know how they works?

I have read many tutorials and I cannot never use theses extensions. I do not even know if they are installed correctly or not (in Special:Version) they appear but nothing changes.

MarkAHershberger (talkcontribs)

Is there a particular extension you're having trouble with? The instructions are similar for each one, but it would help to have a specific one to know what you've tried and what didn't work.

Reply to "Installing extensions"