Project:Support desk/Flow/2019/07

This page is an archive.
Please ask questions on the current support desk.
Category:Support desk archives#Flow%20Archive%20Support%20desk/Flow/2019/07

recommendation for a good installation

Greetings.

I need to install half wiki in UTF-8. I have seen many tutorials that are usually installed by the binary database, although I think it should not be installed in binary if you want to migrate the wiki to another server easily.

When I try to install it on my server and my PC, I do not have the option to install it in UTF-8. Can someone tell me what is due?

Features:

1) Mediawiki version 1.32.2

2) PHP 7.0.33 (server) and PHP 7.2.4 (localhost)

3) MariaDB 10.2.25

4) Apache / 2.4.33

Link:

https://i.ibb.co/2YZWsRr/utf-8-bd.png Senseidb (talk) 00:46, 1 July 2019 (UTC)

An RFC was created and discussed last year to implement this change. It was implemented and backported to MW 1.31 last june.
The reason is that using UTF-8 causes unexpected problems, but you can read more about that in the RFC.
You shouldn't have trouble moving your wiki to another server. If you do, please file a bug and let us know. MarkAHershberger(talk) 01:43, 1 July 2019 (UTC)
The detail is when maintenance is required or it is required to give a solution directly from the database.
If you save the absolute path of the database in binary how do I migrate the database to a new domain?
I think that if the database were in UTF-8 and a migration is required, simply using a script would replace the routes and the migration would be made easier.
I know that in binary a security issue could be useful, although I prefer that it be in UTF-8 in my development server. I'm still experimenting with the mediawiki before passing it to a development server.
Note:
Is there any mediawiki payment support? Senseidb (talk) 13:45, 1 July 2019 (UTC)
There are people who will work on your site for pay, yes. I am one of them. Email me if you're interested.
I think you have a misconception about how binary encoding vs UTF-8 encoding works in the database. The experience of MediaWiki developers with UTF-8 encoding was so problematic that they have decided to take away that option.
In any case, maintenance of your DB for MediaWiki should not involve directly executing any SQL commands. MarkAHershberger(talk) 15:48, 1 July 2019 (UTC)
Ok I understand, thanks for the answers. By the way, I just sent you an email to contact you. Senseidb (talk) 03:21, 2 July 2019 (UTC)

Error when updating wiki

When adding extensions/UserPageViewTracker, after adding wfLoadExtension( 'UserPageViewTracker' ); I tried updating as in Manual:Upgrading#Web browser but I get this error on Upgrade an existing installation page, I get it again and again even when I hit Continue.

Function: Wikimedia\Rdbms\Database::sourceFile( /homepages/32/****/htdocs/****/mediawiki-1.32.0/extensions/UserPageViewTracker/UserPageViewTracker.sql )

Error: 1 near "OR": syntax error

Purging caches...done


Here is what is writen in UserPageViewTracker.sql

CREATE TABLE IF NOT EXISTS /*_*/user_page_views (

   user_id INT(5) UNSIGNED NOT NULL,

   page_id INT(8) UNSIGNED NOT NULL,

   hits INT(10) UNSIGNED NOT NULL,

   last CHAR(14) DEFAULT NULL,

   PRIMARY KEY ( user_id, page_id )

);

CREATE OR REPLACE VIEW /*_*/user_page_hits AS SELECT,

   u.user_name AS user_name,

   u.user_real_name AS user_real_name,

   p.page_namespace AS page_namespace,

   p.page_title AS page_title,

   v.hits AS hits,

   v.last AS last

FROM (/*_*/user u JOIN /*_*/page p) JOIN /*_*/user_page_views v

WHERE u.user_id = v.user_id AND p.page_id = v.page_id

ORDER BY u.user_id, v.hits DESC;


What can I do ? 2610S (talk) 05:26, 1 July 2019 (UTC)

Disable Extension:UserPageViewTracker and then try updating again. The extension may have become outdated now. AhmadF.Cheema (talk) 08:00, 1 July 2019 (UTC)

Problems with uploading images

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


I have problems with uploading files in wikimedia, it turns out that in the same installation activate the option to upload files. I also know that you can edit localSetting.php to activate the option.

At the beginning everything worked correctly, then for some reason blocked the option of uploading images. If I inspect the page and observe that the image uploading service is still available, I only need to deactivate "display: none;" so that it can be activated. However, that is manually.

I do not understand what happens. I just installed the mediawiki and the file upload is disabled soon after. I just started to enter content and set the URL to be friendly according to the mediawiki manual.


look at the following link so you can understand me:

https://i.ibb.co/XZ9JBB7/wiki-upload-problems.png


Please help me...


Some additional information:

1) I use the version of mediawiki-1.32.2.tar.gz

2) Normal installation and activation to upload images in LocalSettings.php

   $wgEnableUploads = true;

   $wgUseImageMagick = true;

3) pretty url setting

   i used this manual

   https://www.mediawiki.org/wiki/Manual:Short_URL/wiki/Page_Title_--_.htaccess

   and it works... :)

4) upload some content (plain text only)

5) PHP Version 7.2.19 | 10.2.25-MariaDB | Apache 2.0 Senseidb (talk) 06:23, 1 July 2019 (UTC)

Can you provide a link to your MediaWiki website? AhmadF.Cheema (talk) 07:59, 1 July 2019 (UTC)
yes of course, here you are:
https://wiki.escuelaregistral.com/wiki/P%C3%A1gina_principal

Senseidb (talk) 13:35, 1 July 2019 (UTC)
In your Wiki's MediaWiki:Common.css, you have the following:
/* Hay consenso en evitar subidas locales de archivos. Trampas CSS para ocultar a los novatos que se pueden subir archivos. */
#t-upload, #mw-upload-form {
	display: none;
	speak: none;
}
Why is that there? Try removing this part, maybe that's the issue.
To take a deeper look, will need to create an account on your Wiki. AhmadF.Cheema (talk) 15:10, 1 July 2019 (UTC)
Thank you.
It is true, I copied the CSS from another mediawiki project and I did not realize that this CSS code line affected the upload of files on the server.
again thank you very much. I will continue experimenting with this web application that I think is ideal for an acedemic project. Senseidb (talk) 17:35, 1 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Second wiki, same installation, second site keeps redirecting to first wiki

I have a working wiki, MW 1.31.1 running on WS 2012 R2, IIS 8.5, let's say http://firstwiki/w/. I'm trying to set up a second wiki (wiki farm) using the same installation files on a separate IIS site, e.g. http://secondwiki/, that points to a separate root folder. I started by copying all the files from the first wiki to the second, into a w/ folder in the second site root folder. Deleted the copied LocalSettings.php and re-installed the site. I specified a different DB name. Putting the new LocalSettings.php into the second wiki folder I was able to browse to the new wiki, http://secondwiki/w/, no content as expected.

I then deleted all the folders, except images, cache and mw-config, from the second wiki install folder, then used mklink /D pathToLink pathToTarget in Command Prompt as per here to point the links in the second wiki folder to their counterpart in the first wiki folder. Now, every time I browse to the second wiki, e.g. http://secondwiki/w/, it automatically redirects me to http://firstwiki/w/ and the first wiki. Going directly to http://secondwiki/w/index.php shows the contents from the first wiki, though with broken image links.

I can't for the life of me figure out what is causing the redirect. I've deleted all the URL Rewrite rules (I had used Short URL on the first wiki) along with the associated codes in LocalSettings.php from both sites. The fact that I was able to browse to the second wiki site, clean with no content, makes me think that it's not IIS. What could it be? I don't remember hardcoding http://firstwiki/w/ into any code in those folders I symlink'ed. Should I have used junction or virtual directories? Tommy H (talk) 08:38, 1 July 2019 (UTC)

Are you using the same LocalSettings.php file for both Wikis? AhmadF.Cheema (talk) 12:22, 1 July 2019 (UTC)
No, separate LocalSettings.php files. The original one is intact in the first wiki folder. The second one is newly created by the installation script. When i browsed to the second wiki URL prior to doing the symlink, it showed the wiki as a plain vanilla wiki, with no content. After I had done the symlink, it started to redirect to the first wiki if I go to http://secondwiki/w/. It also showed the first wiki Main Page with broken image links if I go to http://secondwiki/w/index.php directly. Tommy H (talk) 17:01, 1 July 2019 (UTC)
{{ping|Tommyheyser| AhmadF.Cheema}} Another way to install a second wiki, which is very easy, is to install a second instance of mediawiki as a Bitnami MediaWiki Stack (which includes all the underlying support programs needed). Once you download the install script, it can be run as many times as you like, and each of the instances won't interfere with any other mediawiki instances. Each instance is accessed via its own url, which you can drag to your bookmarks bar.
The install script does all the heavy lifting, and all you have to do is fill in the blanks it provides (wiki's name, the name of the new directory you want it all to go in, etc.).
Download it from https://bitnami.com/stack/mediawiki/installer
Once you install, be sure to read the readme.txt file for start/stop instructions.

The Transhumanist (talk) 09:19, 10 July 2019 (UTC)

The following source code is available in my Sidebar menu markup:

*navigation
**mainpage|mainpage-description
**recentchanges-url|recentchanges
**https://example.com/index.php?title=some-title|some-title

The natively created CSS IDs for these menu items are very long and include dots and backslashes; for example:

"#n-\.D7\.A2\.D7\.A8\.D7\.99\.D7\.9B\.D7\.AA-\.D7\.AA\.D7\.A4\.D7\.A8\.D7\.99\.D7\.98-\.D7\.96\.D7\.94"

I don't want to use these, I prefer to create my own CSS selectors.

How could I add CSS selectors to the Sidebar menu items? 182.232.39.14 (talk) 09:50, 1 July 2019 (UTC)

I would prefer to do this without an extension. 182.232.39.14 (talk) 10:59, 1 July 2019 (UTC)
What is your MediaWiki version?
Have you checked the CSS IDs of the sidebar items on this site? Are those what you want? AhmadF.Cheema (talk) 12:27, 1 July 2019 (UTC)
1.32.0; and yes, these are the ones and I need something of that sort (of what's available here) but mine are significantly longer (maybe due to the site being RTL?). 49.230.62.64 (talk) 17:35, 1 July 2019 (UTC)
@AhmadF.Cheema ? 49.230.62.64 (talk) 23:24, 1 July 2019 (UTC)
Not sure about this, Wikipedia's RTL language versions (like Hebrew) also appear to have the shorter IDs. AhmadF.Cheema (talk) 00:59, 2 July 2019 (UTC)
@AhmadF.Cheema if the menu links are in English they do, but if they are in Hebrew (and likely, other RTL lanugages as well), they don't; then they will have the super-long inefficient IDs such as the one I exampled... 49.230.62.64 (talk) 08:59, 2 July 2019 (UTC)
In case they were customally created, at least. 49.230.62.64 (talk) 09:19, 2 July 2019 (UTC)
Related:
Project:Support desk/Flow/2019/07#h-Preventing_translation_in_sidebar_menu-2019-07-01T18:19:00.000Z 49.230.62.64 (talk) 14:34, 2 July 2019 (UTC)
Check out hewiki's sidebar and note that items like ייעוץ are represented in the sidebar as Ask-q-url|Ask-q. Meanwhile, מדיה_ויקי:Ask-q-url contains ויקיפדיה:ייעוץ (which is where the URL points) and מדיה_ויקי:Ask-q contains ייעוץ which is the label for the link.
Finally, the CSS id on the link is #n-Ask-q which corresponds with the label of the link.
So, for your sidebar, instead of
*navigation
**mainpage|mainpage-description
**recentchanges-url|recentchanges
**https://example.com/index.php?title=some-title|some-title
try
*navigation
**mainpage|mainpage-description
**recentchanges-url|recentchanges
**some-title-link|some-title
And create that pages [[MediaWiki:Some-title-link]] containing some-title-on-your-wiki and [[MediaWiki:Some-title]] contataining the text label for your link.
At that point the css id for your link should be #n-some-title. MarkAHershberger(talk) 16:51, 2 July 2019 (UTC)

Style and mbstring.func_overload Problem - Follow Up

This is just the follow-up of the already described "Style and mbstring.func_overload Problem" - I just got a login to follow this better.


Versions:

MediaWiki 1.32.1

PHP 7.2.19

MySQL 5.6.44

ICU 63.1


As described, the problem is, that sometimes, the CSS does not display and also the error

" MediaWiki does not support installations where mbstring.func_overload is non-zero." shows up, although, it is set to zero.


I tried to debug by changing LocalSettings.php to display the PHP errors, but this did not make the errors show. I added the following lines in the second row.

$wgShowExceptionDetails = true;

$wgDevelopmentWarnings = true; error_reporting( -1 ); ini_set( 'display_errors', 1);


When I open the page in Chrome, I get the error message:

Refused to execute script from 'https://wiki.xxx.de/load.php?debug=false&lang=en&modules=startup&only=scripts&skin=vector' because its MIME type ('text/html') is not executable, and strict MIME type checking is enabled.


I found different posts online describing similar, but not the same problem. One such problem was resolved by updating, however, I already run the latest version.


I created a web.config file and wrote the rewrite rules described here. However, I have not implemented short URLs.


I am sorry that I cannot share the URL.


I am looking forward to hearing from you.


Many thanks SebastianKazan (talk) 13:28, 1 July 2019 (UTC)

What is the content of the page when you see the "Refused to execute script..." message? You may need to use view source to see it.
I suspect that error messages and warnings are creeping into the page being served and that is what is causing it to be text/html. MarkAHershberger(talk) 15:52, 1 July 2019 (UTC)
Hello Mark,
the content is either the page in the way that it should be displayed or in its broken shape or when the mbstring error comes the source is:
MediaWiki does not support installations where mbstring.func_overload is non-zero.
The source of the broken page is very large... Could I send you a file with it?
Thank you SebastianKazan (talk) 16:30, 1 July 2019 (UTC)
sure, If you can post it to dropbox or pasting it somewhere might help, too. MarkAHershberger(talk) 17:35, 1 July 2019 (UTC)
Good morning,
so here is what comes up when I click on "Source" in Chrome:
https://wiki.xyz.de/index.php?title=L%C3%A4rmanalyse_1
https://wiki.xyz.de/load.php?debug=false&lang=en&modules=startup&only=scripts&skin=vector
https://wiki.xyz.de/load.php?debug=false&lang=en&modules=mediawiki.legacy.commonPrint%2Cshared%7Cmediawiki.skinning.interface%7Cmediawiki.toc.styles%7Cskins.vector.styles&only=styles&skin=vector SebastianKazan (talk) 07:29, 2 July 2019 (UTC)
That doesn't look like the contents of view-source and, if it is, I can understand why your browser would balk at that. MarkAHershberger(talk) 17:06, 2 July 2019 (UTC)
Sorry, I had a misconception of what view source meant.
This should be it:
html output
SebastianKazan (talk) 06:20, 3 July 2019 (UTC)
Is this the content of the page when Chrome shows the message "Refused to execute script..."? If not, what does view-source show when Chrome says it refused to execute? MarkAHershberger(talk) 17:21, 3 July 2019 (UTC)
Exactly. This is the view-source when this "Refused to execute script..." message appears. This error is almost always there, irrespective of wether the CSS is properly displayed or not. SebastianKazan (talk) 07:39, 4 July 2019 (UTC)
The message you are getting from Chrome, though, complains about load.php. What is the output of the load.php url (you gave https://wiki.xxx.de/load.php?debug=false&lang=en&modules=startup&only=scripts&skin=vector above) when chrome says that? MarkAHershberger(talk) 18:30, 4 July 2019 (UTC)
When I copy the URL with the load.php in the browser it says:
css output
@media print{.noprint,.catlinks,.magnify,.mw-cite-backlink,.mw-editsection,.mw-editsection-like,.mw-hidden-catlinks,.mw-indicators,.mw-redirectedfrom,.patrollink,.usermessage,#column-one,#footer-places,#mw-navigation,#siteNotice,#f-poweredbyico,#f-copyrightico,li#about,li#disclaimer,li#mobileview,li#privacy{display:none}body{background:#fff;color:#000;margin:0;padding:0}a{background:none !important;padding:0 !important}a,a.external,a.new,a.stub{color:#000 !important;text-decoration:none !important;color:inherit !important;text-decoration:inherit !important}.mw-parser-output a.external.text:after,.mw-parser-output a.external.autonumber:after{content:' (' attr(href) ')';word-break:break-all;word-wrap:break-word}.mw-parser-output a.external.text[href^='//']:after,.mw-parser-output a.external.autonumber[href^='//']:after{content:' (https:' attr(href) ')'}dt{font-weight:bold}h1,h2,h3,h4,h5,h6{font-weight:bold;page-break-after:avoid;page-break-before:avoid}p{margin:1em 0;line-height:1.2;orphans:3;widows:3}img,figure,.wikitable,.thumb{page-break-inside:avoid}img{border:0;vertical-align:middle}pre,.mw-code{background:#fff;color:#000;border:1pt dashed #000;padding:1em 0;font-size:8pt;white-space:pre-wrap;word-wrap:break-word}sup,sub{line-height:1}ul{list-style-type:square}#globalWrapper{width:100% !important;min-width:0 !important}.mw-body{background:#fff;color:#000;border:0 !important;padding:0 !important;margin:0 !important;direction:ltr}#column-content{margin:0 !important}#column-content .mw-body{padding:1em;margin:0 !important}.toc{background-color:#f9f9f9;border:1pt solid #aaa;padding:5px;display:table}.tocnumber,.toctext{display:table-cell}.tocnumber{padding-left:0;padding-right:0.5em}.mw-content-ltr .tocnumber{padding-left:0;padding-right:0.5em}.mw-content-rtl .tocnumber{padding-left:0.5em;padding-right:0}table.floatright,div.floatright,div.tright{float:right;clear:right;position:relative}table.floatleft,div.floatleft,div.tleft{float:left;clear:left;position:relative}div.tleft{margin:0.5em 1.4em 1.3em 0}div.tright{margin:0.5em 0 1.3em 1.4em}table.floatright,div.floatright{margin:0 0 0.5em 0.5em;border:0}table.floatleft,div.floatleft{margin:0 0.5em 0.5em 0;border:0}.center{text-align:center}div.thumb{background-color:transparent;width:auto}div.thumb a{border-bottom:0}div.thumbinner{background-color:#fff;border:0;border-radius:2px;padding:5px;font-size:10pt;color:#666;text-align:center;overflow:hidden;min-width:100px}html .thumbcaption{text-align:left;line-height:1.4;padding:3px}img.thumbborder{border:1pt solid #ddd}table.wikitable,.mw_metadata{background:#fff;margin:1em 0;border:1pt solid #aaa;border-collapse:collapse;font-size:10pt}table.wikitable > caption,.mw_metadata caption{padding:5px;font-size:10pt}table.wikitable > tr > th,table.wikitable > tr > td,table.wikitable > * > tr > th,table.wikitable > * > tr > td,.mw_metadata th,.mw_metadata td{background:#fff !important;color:#000 !important;border:1pt solid #aaa;padding:0.4em 0.6em}table.wikitable > tr > th,table.wikitable > * > tr > th,.mw_metadata th{text-align:center}table.listing,table.listing td{border:1pt solid #000;border-collapse:collapse}.catlinks ul{display:inline;padding:0;list-style:none none}.catlinks li{display:inline-block;line-height:1.15;margin:0.1em 0;border-left:1pt solid #aaa;padding:0 0.4em}.catlinks li:first-child{border-left:0;padding-left:0.2em}.printfooter{padding:1em 0}#footer{background:#fff;color:#000;margin-top:1em;border-top:1pt solid #aaa;padding-top:5px;direction:ltr}}@media screen{.mw-content-ltr{direction:ltr}.mw-content-rtl{direction:rtl}.sitedir-ltr textarea,.sitedir-ltr input{direction:ltr}.sitedir-rtl textarea,.sitedir-rtl input{direction:rtl}.mw-userlink{unicode-bidi:embed}mark{background-color:#ff0;color:#000}wbr{display:inline-block}input[type='submit'],input[type='button'],input[type='reset'],input[type='file']{direction:ltr}textarea[dir='ltr'],input[dir='ltr']{direction:ltr}textarea[dir='rtl'],input[dir='rtl']{direction:rtl}abbr[title],.explain[title]{border-bottom:1px dotted;cursor:help}@supports (text-decoration:underline dotted){abbr[title],.explain[title]{border-bottom:0;text-decoration:underline dotted}}span.comment{font-style:italic;unicode-bidi:-moz-isolate;unicode-bidi:isolate}#editform,#toolbar,#wpTextbox1{clear:both}#toolbar{height:22px}.mw-underline-always a{text-decoration:underline}.mw-underline-never a{text-decoration:none}li span.deleted,span.history-deleted{text-decoration:line-through;color:#72777d;font-style:italic}.not-patrolled{background-color:#ffa}.unpatrolled{font-weight:bold;color:#d33}div.patrollink{font-size:75%;text-align:right}td.mw-label{text-align:right;vertical-align:middle}td.mw-input{text-align:left}td.mw-submit{text-align:left;white-space:nowrap}.mw-input-with-label{white-space:nowrap;display:inline-block}.mw-content-ltr .thumbcaption{text-align:left}.mw-content-ltr .magnify{float:right}.mw-content-rtl .thumbcaption{text-align:right}.mw-content-rtl .magnify{float:left}#catlinks{text-align:left}.catlinks ul{display:inline;margin:0;padding:0;list-style:none none;vertical-align:middle !ie}.catlinks li{display:inline-block;line-height:1.25em;border-left:1px solid #a2a9b1;margin:0.125em 0;padding:0 0.5em;zoom:1;display:inline !ie}.catlinks li:first-child{padding-left:0.25em;border-left:0}.catlinks li a.mw-redirect{font-style:italic}.mw-hidden-cats-hidden{display:none}.catlinks-allhidden{display:none}p.mw-protect-editreasons,p.mw-filedelete-editreasons,p.mw-delete-editreasons{font-size:90%;text-align:right}.autocomment{color:#72777d}.newpage,.minoredit,.botedit{font-weight:bold}div.mw-warning-with-logexcerpt{padding:3px;margin-bottom:3px;border:2px solid #2a4b8d;clear:both}div.mw-warning-with-logexcerpt ul li{font-size:90%}span.mw-revdelundel-link,strong.mw-revdelundel-link{font-size:90%}span.mw-revdelundel-hidden,input.mw-revdelundel-hidden{visibility:hidden}td.mw-revdel-checkbox,th.mw-revdel-checkbox{padding-right:10px;text-align:center}a.new{color:#ba0000}.plainlinks a.external{background:none !important;padding:0 !important}.rtl a.external.free,.rtl a.external.autonumber{direction:ltr;unicode-bidi:embed}table.wikitable{background-color:#f8f9fa;color:#222;margin:1em 0;border:1px solid #a2a9b1;border-collapse:collapse}table.wikitable > tr > th,table.wikitable > tr > td,table.wikitable > * > tr > th,table.wikitable > * > tr > td{border:1px solid #a2a9b1;padding:0.2em 0.4em}table.wikitable > tr > th,table.wikitable > * > tr > th{background-color:#eaecf0;text-align:center}table.wikitable > caption{font-weight:bold}.error,.warning,.success{font-size:larger}.error{color:#d33}.warning{color:#705000}.success{color:#009000}.errorbox,.warningbox,.successbox{border:1px solid;padding:0.5em 1em;margin-bottom:1em;display:inline-block;zoom:1;*display:inline}.errorbox h2,.warningbox h2,.successbox h2{font-size:1em;color:inherit;font-weight:bold;display:inline;margin:0 0.5em 0 0;border:0}.errorbox{color:#d33;border-color:#fac5c5;background-color:#fae3e3}.warningbox{color:#705000;border-color:#fde29b;background-color:#fdf1d1}.successbox{color:#008000;border-color:#b7fdb5;background-color:#e1fddf}.mw-infobox{border:2px solid #ff7f00;margin:0.5em;clear:left;overflow:hidden}.mw-infobox-left{margin:7px;float:left;width:35px}.mw-infobox-right{margin:0.5em 0.5em 0.5em 49px}.previewnote{color:#d33;margin-bottom:1em}.previewnote p{text-indent:3em;margin:0.8em 0}.visualClear{clear:both}.mw-datatable{border-collapse:collapse}.mw-datatable,.mw-datatable td,.mw-datatable th{border:1px solid #a2a9b1;padding:0 0.15em 0 0.15em}.mw-datatable th{background-color:#ddf}.mw-datatable td{background-color:#fff}.mw-datatable tr:hover td{background-color:#eaf3ff}.mw-content-ltr ul,.mw-content-rtl .mw-content-ltr ul{margin:0.3em 0 0 1.6em;padding:0}.mw-content-rtl ul,.mw-content-ltr .mw-content-rtl ul{margin:0.3em 1.6em 0 0;padding:0}.mw-content-ltr ol,.mw-content-rtl .mw-content-ltr ol{margin:0.3em 0 0 3.2em;padding:0}.mw-content-rtl ol,.mw-content-ltr .mw-content-rtl ol{margin:0.3em 3.2em 0 0;padding:0}.mw-content-ltr dd,.mw-content-rtl .mw-content-ltr dd{margin-left:1.6em;margin-right:0}.mw-content-rtl dd,.mw-content-ltr .mw-content-rtl dd{margin-right:1.6em;margin-left:0}.mw-ajax-loader{background-image:url(/resources/src/mediawiki.legacy/images/ajax-loader.gif?57f34);background-position:center center;background-repeat:no-repeat;padding:16px;position:relative;top:-16px}.mw-small-spinner{padding:10px !important;margin-right:0.6em;background-image:url(/resources/src/mediawiki.legacy/images/spinner.gif?ca65b);background-position:center center;background-repeat:no-repeat}h1:lang(anp),h1:lang(as),h1:lang(bh),h1:lang(bho),h1:lang(bn),h1:lang(gu),h1:lang(hi),h1:lang(kn),h1:lang(ks),h1:lang(ml),h1:lang(mr),h1:lang(my),h1:lang(mai),h1:lang(ne),h1:lang(new),h1:lang(or),h1:lang(pa),h1:lang(pi),h1:lang(sa),h1:lang(ta),h1:lang(te){line-height:1.6em !important}h2:lang(anp),h3:lang(anp),h4:lang(anp),h5:lang(anp),h6:lang(anp),h2:lang(as),h3:lang(as),h4:lang(as),h5:lang(as),h6:lang(as),h2:lang(bho),h3:lang(bho),h4:lang(bho),h5:lang(bho),h6:lang(bho),h2:lang(bh),h3:lang(bh),h4:lang(bh),h5:lang(bh),h6:lang(bh),h2:lang(bn),h3:lang(bn),h4:lang(bn),h5:lang(bn),h6:lang(bn),h2:lang(gu),h3:lang(gu),h4:lang(gu),h5:lang(gu),h6:lang(gu),h2:lang(hi),h3:lang(hi),h4:lang(hi),h5:lang(hi),h6:lang(hi),h2:lang(kn),h3:lang(kn),h4:lang(kn),h5:lang(kn),h6:lang(kn),h2:lang(ks),h3:lang(ks),h4:lang(ks),h5:lang(ks),h6:lang(ks),h2:lang(ml),h3:lang(ml),h4:lang(ml),h5:lang(ml),h6:lang(ml),h2:lang(mr),h3:lang(mr),h4:lang(mr),h5:lang(mr),h6:lang(mr),h2:lang(my),h3:lang(my),h4:lang(my),h5:lang(my),h6:lang(my),h2:lang(mai),h3:lang(mai),h4:lang(mai),h5:lang(mai),h6:lang(mai),h2:lang(ne),h3:lang(ne),h4:lang(ne),h5:lang(ne),h6:lang(ne),h2:lang(new),h3:lang(new),h4:lang(new),h5:lang(new),h6:lang(new),h2:lang(or),h3:lang(or),h4:lang(or),h5:lang(or),h6:lang(or),h2:lang(pa),h3:lang(pa),h4:lang(pa),h5:lang(pa),h6:lang(pa),h2:lang(pi),h3:lang(pi),h4:lang(pi),h5:lang(pi),h6:lang(pi),h2:lang(sa),h3:lang(sa),h4:lang(sa),h5:lang(sa),h6:lang(sa),h2:lang(ta),h3:lang(ta),h4:lang(ta),h5:lang(ta),h6:lang(ta),h2:lang(te),h3:lang(te),h4:lang(te),h5:lang(te),h6:lang(te){line-height:1.2em}ol:lang(azb) li,ol:lang(bcc) li,ol:lang(bgn) li,ol:lang(bqi) li,ol:lang(fa) li,ol:lang(glk) li,ol:lang(kk-arab) li,ol:lang(lrc) li,ol:lang(luz) li,ol:lang(mzn) li{list-style-type:-moz-persian;list-style-type:persian}ol:lang(ckb) li,ol:lang(sdh) li{list-style-type:-moz-arabic-indic;list-style-type:arabic-indic}ol:lang(hi) li,ol:lang(mai) li,ol:lang(mr) li,ol:lang(ne) li{list-style-type:-moz-devanagari;list-style-type:devanagari}ol:lang(as) li,ol:lang(bn) li{list-style-type:-moz-bengali;list-style-type:bengali}ol:lang(or) li{list-style-type:-moz-oriya;list-style-type:oriya}.toc ul{margin:0.3em 0}.mw-content-ltr .toc ul,.mw-content-rtl .mw-content-ltr .toc ul{text-align:left}.mw-content-rtl .toc ul,.mw-content-ltr .mw-content-rtl .toc ul{text-align:right}.mw-content-ltr .toc ul ul,.mw-content-rtl .mw-content-ltr .toc ul ul{margin:0 0 0 2em}.mw-content-rtl .toc ul ul,.mw-content-ltr .mw-content-rtl .toc ul ul{margin:0 2em 0 0}.toc .toctitle{direction:ltr}#mw-clearyourcache,#mw-sitecsspreview,#mw-sitejspreview,#mw-usercsspreview,#mw-userjspreview{direction:ltr;unicode-bidi:embed}#mw-revision-info,#mw-revision-info-current,#mw-revision-nav{direction:ltr}div.tright,div.floatright,table.floatright{clear:right;float:right}div.tleft,div.floatleft,table.floatleft{float:left;clear:left}div.floatright,table.floatright,div.floatleft,table.floatleft{position:relative}#mw-credits a{unicode-bidi:embed}.printfooter{display:none}.xdebug-error{position:absolute;z-index:99}.mw-editsection{-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none}.mw-editsection,.mw-editsection-like{font-size:small;font-weight:normal;margin-left:1em;vertical-align:baseline;line-height:1em}.mw-content-ltr .mw-editsection,.mw-content-rtl .mw-content-ltr .mw-editsection{margin-left:1em}.mw-content-rtl .mw-editsection,.mw-content-ltr .mw-content-rtl .mw-editsection{margin-right:1em}sup,sub{line-height:1}}@media screen{a{text-decoration:none;color:#0645ad;background:none}a:not([href]){cursor:pointer}a:visited{color:#0b0080}a:active{color:#faa700}a:hover,a:focus{text-decoration:underline}a:lang(ar),a:lang(kk-arab),a:lang(mzn),a:lang(ps),a:lang(ur){text-decoration:none}a.stub{color:#723}a.new,#p-personal a.new{color:#ba0000}a.mw-selflink{color:inherit;font-weight:bold;text-decoration:inherit}a.mw-selflink:hover{cursor:inherit;text-decoration:inherit}a.mw-selflink:active,a.mw-selflink:visited{color:inherit}a.new:visited,#p-personal a.new:visited{color:#a55858}.mw-parser-output a.extiw,.mw-parser-output a.extiw:active{color:#36b}.mw-parser-output a.extiw:visited{color:#636}.mw-parser-output a.extiw:active{color:#b63}.mw-parser-output a.external{color:#36b}.mw-parser-output a.external:visited{color:#636}.mw-parser-output a.external:active{color:#b63}.mw-parser-output a.external.free{word-wrap:break-word}img{border:0;vertical-align:middle}hr{height:1px;color:#a2a9b1;background-color:#a2a9b1;border:0;margin:0.2em 0}h1,h2,h3,h4,h5,h6{color:#000;background:none;font-weight:normal;margin:0;overflow:hidden;padding-top:0.5em;padding-bottom:0.17em;border-bottom:1px solid #a2a9b1}h1{font-size:188%}h2{font-size:150%}h3,h4,h5,h6{border-bottom:0;font-weight:bold}h3{font-size:128%}h4{font-size:116%}h5{font-size:108%}h6{font-size:100%}h1,h2{margin-bottom:0.6em}h3,h4,h5{margin-bottom:0.3em}p{margin:0.4em 0 0.5em 0}p img{margin:0}ul{list-style-type:square;margin:0.3em 0 0 1.6em;padding:0}ol{margin:0.3em 0 0 3.2em;padding:0;list-style-image:none}li{margin-bottom:0.1em}dt{font-weight:bold;margin-bottom:0.1em}dl{margin-top:0.2em;margin-bottom:0.5em}dd{margin-left:1.6em;margin-bottom:0.1em}pre,code,tt,kbd,samp,.mw-code{font-family:monospace,monospace}code{color:#000;background-color:#f8f9fa;border:1px solid #eaecf0;border-radius:2px;padding:1px 4px}pre,.mw-code{color:#000;background-color:#f8f9fa;border:1px solid #eaecf0;padding:1em;white-space:pre-wrap}table{font-size:100%}fieldset{border:1px solid #2a4b8d;margin:1em 0 1em 0;padding:0 1em 1em}fieldset.nested{margin:0 0 0.5em 0;padding:0 0.5em 0.5em}legend{padding:0.5em;font-size:95%}form{border:0;margin:0}textarea{width:100%;padding:0.1em;display:block;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}.center{width:100%;text-align:center}*.center *{margin-left:auto;margin-right:auto}.small{font-size:94%}table.small{font-size:100%}.toc,.mw-warning,.toccolours{border:1px solid #a2a9b1;background-color:#f8f9fa;padding:5px;font-size:95%}.toc{display:inline-block;display:table;zoom:1;*display:inline;padding:7px}table.toc{border-collapse:collapse}table.toc td{padding:0}.toc h2{display:inline;border:0;padding:0;font-size:100%;font-weight:bold}.toc .toctitle{text-align:center}.toc ul{list-style-type:none;list-style-image:none;margin-left:0;padding:0;text-align:left}.toc ul ul{margin:0 0 0 2em}.tocnumber,.toctext{display:table-cell;text-decoration:inherit}.tocnumber{padding-left:0;padding-right:0.5em;color:#222}.mw-content-ltr .tocnumber{padding-left:0;padding-right:0.5em}.mw-content-rtl .tocnumber{padding-left:0.5em;padding-right:0}.mw-warning{margin-left:50px;margin-right:50px;text-align:center}div.floatright,table.floatright{margin:0 0 0.5em 0.5em}div.floatleft,table.floatleft{margin:0 0.5em 0.5em 0}div.thumb{margin-bottom:0.5em;width:auto;background-color:transparent}div.thumbinner{border:1px solid #c8ccd1;padding:3px;background-color:#f8f9fa;font-size:94%;text-align:center;overflow:hidden}html .thumbimage{background-color:#fff;border:1px solid #c8ccd1}html .thumbcaption{border:0;line-height:1.4em;padding:3px;font-size:94%;text-align:left}div.magnify{float:right;margin-left:3px}div.magnify a{display:block;text-indent:15px;white-space:nowrap;overflow:hidden;width:15px;height:11px;background-image:url(/resources/src/mediawiki.skinning/images/magnify-clip-ltr.png?4f704);background-image:linear-gradient(transparent,transparent),url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 11 15%22 width=%2215%22 height=%2211%22%3E %3Cg id=%22magnify-clip%22 fill=%22%23fff%22 stroke=%22%23000%22%3E %3Cpath id=%22bigbox%22 d=%22M1.509 1.865h10.99v7.919h-10.99z%22/%3E %3Cpath id=%22smallbox%22 d=%22M-1.499 6.868h5.943v4.904h-5.943z%22/%3E %3C/g%3E %3C/svg%3E");-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none}img.thumbborder{border:1px solid #eaecf0}.mw-content-ltr .thumbcaption{text-align:left}.mw-content-ltr .magnify{float:right;margin-left:3px;margin-right:0}.mw-content-ltr div.magnify a{background-image:url(/resources/src/mediawiki.skinning/images/magnify-clip-ltr.png?4f704);background-image:linear-gradient(transparent,transparent),url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 11 15%22 width=%2215%22 height=%2211%22%3E %3Cg id=%22magnify-clip%22 fill=%22%23fff%22 stroke=%22%23000%22%3E %3Cpath id=%22bigbox%22 d=%22M1.509 1.865h10.99v7.919h-10.99z%22/%3E %3Cpath id=%22smallbox%22 d=%22M-1.499 6.868h5.943v4.904h-5.943z%22/%3E %3C/g%3E %3C/svg%3E")}.mw-content-rtl .thumbcaption{text-align:right}.mw-content-rtl .magnify{float:left;margin-left:0;margin-right:3px}.mw-content-rtl div.magnify a{background-image:url(/resources/src/mediawiki.skinning/images/magnify-clip-rtl.png?a9fb3);background-image:linear-gradient(transparent,transparent),url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 11 15%22 width=%2215%22 height=%2211%22%3E %3Cg id=%22magnify-clip%22 fill=%22%23fff%22 stroke=%22%23000%22%3E %3Cpath id=%22bigbox%22 d=%22M9.491 1.865h-10.99v7.919h10.99z%22/%3E %3Cpath id=%22smallbox%22 d=%22M12.499 6.868h-5.943v4.904h5.943z%22/%3E %3C/g%3E %3C/svg%3E")}div.tright{margin:0.5em 0 1.3em 1.4em}div.tleft{margin:0.5em 1.4em 1.3em 0}body.mw-hide-empty-elt .mw-empty-elt{display:none}.catlinks{border:1px solid #a2a9b1;background-color:#f8f9fa;padding:5px;margin-top:1em;clear:both}textarea{border:1px solid #c8ccd1}.editOptions{background-color:#eaecf0;color:#222;border:1px solid #c8ccd1;border-top:0;padding:1em 1em 1.5em 1em;margin-bottom:2em}.usermessage{background-color:#ffce7b;border:1px solid #ffa500;color:#000;font-weight:bold;margin:2em 0 1em;padding:0.5em 1em;vertical-align:middle}#siteNotice{position:relative;text-align:center;margin:0}#localNotice{margin-bottom:0.9em}.firstHeading{margin-bottom:0.1em;line-height:1.2em;padding-bottom:0}#siteSub{display:none}#contentSub,#contentSub2{font-size:84%;line-height:1.2em;margin:0 0 1.4em 1em;color:#54595d;width:auto}span.subpages{display:block}}.mw-wiki-logo{background-image:url(/resources/assets/wiki.png?de8c8)}@media screen{html{font-size:100%}html,body{height:100%;margin:0;padding:0;font-family:sans-serif}body{background-color:#f6f6f6}.mw-body,.parsoid-body{padding:1em;background-color:#ffffff;color:#222222;direction:ltr}.mw-body{margin-left:10em;border:1px solid #a7d7f9;border-right-width:0;margin-top:-1px}.mw-body h1,.mw-body-content h1,.mw-body-content h2{font-family:'Linux Libertine','Georgia','Times',serif;line-height:1.3;margin-bottom:0.25em;padding:0}.mw-body h1:lang(ja),.mw-body-content h1:lang(ja),.mw-body-content h2:lang(ja),.mw-body h1:lang(he),.mw-body-content h1:lang(he),.mw-body-content h2:lang(he),.mw-body h1:lang(ko),.mw-body-content h1:lang(ko),.mw-body-content h2:lang(ko){font-family:sans-serif}.mw-body h1:lang(my),.mw-body-content h1:lang(my),.mw-body-content h2:lang(my){line-height:normal}.mw-body h1,.mw-body-content h1{font-size:1.8em}.mw-body .firstHeading{overflow:visible}.mw-body .mw-indicators{float:right;line-height:1.6;font-size:0.875em;position:relative;z-index:1}.mw-body .mw-indicator{display:inline-block;zoom:1;*display:inline}.mw-body-content{position:relative;line-height:1.6;font-size:0.875em;z-index:0}.mw-body-content p{line-height:inherit;margin:0.5em 0}.mw-body-content h1{margin-top:1em}.mw-body-content h2{font-size:1.5em;margin-top:1em}.mw-body-content h3,.mw-body-content h4,.mw-body-content h5,.mw-body-content h6{line-height:1.6;margin-top:0.3em;margin-bottom:0;padding-bottom:0}.mw-body-content h3{font-size:1.2em}.mw-body-content h3,.mw-body-content h4{font-weight:bold}.mw-body-content h4,.mw-body-content h5,.mw-body-content h6{font-size:100%}.mw-body-content .toc h2{font-size:100%;font-family:sans-serif}.mw-editsection,.mw-editsection-like{font-family:sans-serif}div.emptyPortlet{display:none}ul{list-style-type:disc;list-style-image:url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%225%22 height=%2213%22%3E %3Ccircle cx=%222.5%22 cy=%229.5%22 r=%222.5%22 fill=%22%2300528c%22/%3E %3C/svg%3E");list-style-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAANCAIAAADuXjPfAAAABnRSTlMA/wD/AP83WBt9AAAAHklEQVR4AWP4jwrowWcI6oEgEBtIISNCfFT9mOYDACO/lbNIGC/yAAAAAElFTkSuQmCC) \9;list-style-image:url(/skins/Vector/images/bullet-icon.png?e31f8) \9!ie}pre,.mw-code{line-height:1.3em}#siteNotice{font-size:0.8em}#p-personal{position:absolute;top:0.33em;right:0.75em;z-index:100}#p-personal h3{display:none}#p-personal ul{list-style-type:none;list-style-image:none;margin:0;padding-left:10em}#p-personal li{float:left;margin-left:0.75em;margin-top:0.5em;font-size:0.75em;line-height:1.16666667em;white-space:nowrap}#pt-userpage a,#pt-anonuserpage{background-image:url(/skins/Vector/images/user-avatar.png?59494);background-image:linear-gradient(transparent,transparent),url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%2220%22 height=%2220%22 viewBox=%220 0 20 20%22%3E %3Cg fill=%22%2354595d%22%3E %3Cpath d=%22M10 11c-5.92 0-8 3-8 5v3h16v-3c0-2-2.08-5-8-5z%22/%3E %3Ccircle cx=%2210%22 cy=%225.5%22 r=%224.5%22/%3E %3C/g%3E %3C/svg%3E");background-position:left top;background-repeat:no-repeat;background-size:1.16666667em 1.16666667em;padding-left:16px !important}#pt-anonuserpage{color:#54595d}#p-search{float:left;margin-right:0.5em;margin-left:0.5em}#p-search h3{display:block;position:absolute !important;clip:rect(1px,1px,1px,1px);width:1px;height:1px;margin:-1px;border:0;padding:0;overflow:hidden}#p-search form,#p-search input{margin:0.4em 0 0}#simpleSearch{background-color:#fff;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAQCAIAAABY/YLgAAAAJUlEQVQIHQXBsQEAAAjDoND/73UWdnerhmHVsDQZJrNWVg3Dqge6bgMe6bejNAAAAABJRU5ErkJggg==);background-image:url(/skins/Vector/images/search-fade.png?50f7b)!ie;background-position:top left;background-repeat:repeat-x;color:#000;display:block;width:12.6em;width:20vw;min-width:5em;max-width:20em;padding-right:1.4em;height:1.4em;margin-top:0.65em;position:relative;min-height:1px;border:1px solid #a2a9b1;border-radius:2px;-webkit-transition:border-color 250ms;-moz-transition:border-color 250ms;transition:border-color 250ms}#simpleSearch:hover{border-color:#72777d}#simpleSearch input{background-color:transparent;color:#000;margin:0;padding:0;border:0}#simpleSearch #searchInput{width:100%;padding:0.2em 0 0.2em 0.2em;font-size:0.8125em;direction:ltr;-webkit-appearance:textfield}#simpleSearch #searchInput:focus{outline:0}#simpleSearch #searchInput::-webkit-input-placeholder{color:#72777d;opacity:1}#simpleSearch #searchInput:-ms-input-placeholder{color:#72777d;opacity:1}#simpleSearch #searchInput::-moz-placeholder{color:#72777d;opacity:1}#simpleSearch #searchInput:-moz-placeholder{color:#72777d;opacity:1}#simpleSearch #searchInput::placeholder{color:#72777d;opacity:1}#simpleSearch #searchInput::-webkit-search-decoration,#simpleSearch #searchInput::-webkit-search-cancel-button,#simpleSearch #searchInput::-webkit-search-results-button,#simpleSearch #searchInput::-webkit-search-results-decoration{-webkit-appearance:textfield}#simpleSearch #searchButton,#simpleSearch #mw-searchButton{position:absolute;top:0;right:0;width:1.65em;height:100%;cursor:pointer;text-indent:-99999px;direction:ltr;white-space:nowrap;overflow:hidden}#simpleSearch #searchButton{background-image:url(/skins/Vector/images/search-ltr.png?39f97);background-image:linear-gradient(transparent,transparent),url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%2212%22 height=%2213%22%3E %3Cg fill=%22none%22 stroke=%22%2354595d%22 stroke-width=%222%22%3E %3Cpath d=%22M11.29 11.71l-4-4%22/%3E %3Ccircle cx=%225%22 cy=%225%22 r=%224%22/%3E %3C/g%3E %3C/svg%3E");background-position:center center;background-repeat:no-repeat}#simpleSearch #mw-searchButton{z-index:1}.vectorTabs h3{display:none}.vectorTabs{float:left;height:2.5em;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAuCAIAAABmjeQ9AAAAQ0lEQVR4AWVOhQEAIAzC/X+xAXbXeoDFGA3A9yk1n4juBROcUegfarWjP3ojZvEzxs6j+nygmo+zzsk79nY+tOxdEhlf3UHVgUFrVwAAAABJRU5ErkJggg==);background-image:url(/skins/Vector/images/tab-break.png?09d4b)!ie;background-position:bottom left;background-repeat:no-repeat;padding-left:1px}.vectorTabs ul{float:left;height:100%;list-style-type:none;list-style-image:none;margin:0;padding:0;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAuCAIAAABmjeQ9AAAAQ0lEQVR4AWVOhQEAIAzC/X+xAXbXeoDFGA3A9yk1n4juBROcUegfarWjP3ojZvEzxs6j+nygmo+zzsk79nY+tOxdEhlf3UHVgUFrVwAAAABJRU5ErkJggg==);background-image:url(/skins/Vector/images/tab-break.png?09d4b)!ie;background-position:right bottom;background-repeat:no-repeat}.vectorTabs ul li{float:left;line-height:1.125em;display:block;height:100%;margin:0;padding:0;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAABkCAIAAADITs03AAAAO0lEQVR4AeSKhREAMQzDdN5/5uixuEKDpqgBjl2f78wd2DVj1+26/h///PfteVMN7zoGebcg1/Y/ZQQAlAUtQCujIJMAAAAASUVORK5CYII=);background-image:url(/skins/Vector/images/tab-normal-fade.png?1cc52)!ie;background-position:bottom left;background-repeat:repeat-x;white-space:nowrap}.vectorTabs li.new a,.vectorTabs li.new a:visited{color:#a55858}.vectorTabs li.selected{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAABkAQAAAABvV2fNAAAADElEQVR4AWNoGB4QAInlMgFKeRKBAAAAAElFTkSuQmCC);background-image:url(/skins/Vector/images/tab-current-fade.png?22887)!ie}.vectorTabs li.selected a,.vectorTabs li.selected a:visited{color:#222;text-decoration:none}.vectorTabs li.icon a{background-position:bottom right;background-repeat:no-repeat}.vectorTabs li a{display:block;height:1.9em;padding-left:0.615em;padding-right:0.615em;color:#0645ad;cursor:pointer;font-size:0.8125em}.vectorTabs span{display:inline-block;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAuCAIAAABmjeQ9AAAAQ0lEQVR4AWVOhQEAIAzC/X+xAXbXeoDFGA3A9yk1n4juBROcUegfarWjP3ojZvEzxs6j+nygmo+zzsk79nY+tOxdEhlf3UHVgUFrVwAAAABJRU5ErkJggg==);background-image:url(/skins/Vector/images/tab-break.png?09d4b)!ie;background-position:bottom right;background-repeat:no-repeat;height:100%}.vectorTabs span a{float:left;display:block;position:relative;padding-top:1.25em}.vectorMenu{direction:ltr;float:left;cursor:pointer;position:relative;line-height:1.125em}#mw-head .vectorMenu h3{float:left;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAuCAIAAABmjeQ9AAAAQ0lEQVR4AWVOhQEAIAzC/X+xAXbXeoDFGA3A9yk1n4juBROcUegfarWjP3ojZvEzxs6j+nygmo+zzsk79nY+tOxdEhlf3UHVgUFrVwAAAABJRU5ErkJggg==);background-image:url(/skins/Vector/images/tab-break.png?09d4b)!ie;background-repeat:no-repeat;background-position:bottom right;font-size:1em;height:2.5em;padding:0 0.5em 0 0;margin:0 -1px 0 0}.vectorMenu h3 span{position:relative;display:block;font-size:0.8125em;padding-left:0.615em;padding-top:1.25em;padding-right:16px;font-weight:normal;color:#444}.vectorMenu h3 span:after{content:'';position:absolute;top:1.25em;right:0;bottom:0;left:0;background-image:url(/skins/Vector/images/arrow-down.png?42edd);background-image:linear-gradient(transparent,transparent),url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%2212%22 height=%2212%22 viewBox=%220 0 12 12%22%3E %3Cpath d=%22M11.05 3.996l-.965-1.053-4.035 3.86-3.947-3.86L1.05 3.996l5 5 5-5%22 fill=%22%23222%22/%3E %3C/svg%3E");background-position:100% 50%;background-repeat:no-repeat;opacity:0.85}.vectorMenu h3:hover span,.vectorMenu h3:focus span{color:#222222}.vectorMenu h3:hover span:after,.vectorMenu h3:focus span:after{opacity:1}.vectorMenu .vectorMenuCheckbox:checked + h3 span:after{transform:scaleY(-1)}.vectorMenu .vectorMenuCheckbox:focus + h3{outline:dotted 1px;outline:auto -webkit-focus-ring-color}.vectorMenu .menu{min-width:100%;position:absolute;top:2.5em;left:-1px;background-color:#ffffff;border:1px solid #a2a9b1;border-top-width:0;clear:both;box-shadow:0 1px 1px 0 rgba(0,0,0,0.1);text-align:left;display:none;z-index:2}.vectorMenu:hover .menu{display:block}.vectorMenu .vectorMenuCheckbox:checked ~ .menu{display:block}.vectorMenu ul{list-style-type:none;list-style-image:none;padding:0;margin:0;text-align:left}.vectorMenu li{padding:0;margin:0;text-align:left;line-height:1em}.vectorMenu li a{display:block;padding:0.625em;white-space:nowrap;color:#0645ad;cursor:pointer;font-size:0.8125em}.vectorMenu li.selected a,.vectorMenu li.selected a:visited{color:#222;text-decoration:none}.vectorMenuCheckbox{cursor:pointer;position:absolute;top:0;left:0;z-index:1;opacity:0;width:100%;height:100%;margin:0;padding:0;display:none}:not(:checked) > .vectorMenuCheckbox{display:block}@-webkit-keyframes rotate{from{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);transform:rotate(360deg)}}@-moz-keyframes rotate{from{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes rotate{from{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);transform:rotate(360deg)}}.vectorTabs #ca-unwatch.icon a,.vectorTabs #ca-watch.icon a{margin:0;padding:0;display:block;width:28px;padding-top:3.07692308em;height:0;overflow:hidden;background-position:5px 60%;background-repeat:no-repeat}.vectorTabs #ca-unwatch.icon a{background-image:url(/skins/Vector/images/unwatch-icon.png?fccbe);background-image:linear-gradient(transparent,transparent),url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%2216%22 height=%2216%22 xmlns:xlink=%22http://www.w3.org/1999/xlink%22%3E %3Cdefs%3E %3ClinearGradient id=%22a%22%3E %3Cstop offset=%220%22 stop-color=%22%23c2edff%22/%3E %3Cstop offset=%22.5%22 stop-color=%22%2368bdff%22/%3E %3Cstop offset=%221%22 stop-color=%22%23fff%22/%3E %3C/linearGradient%3E %3ClinearGradient id=%22b%22 x1=%2213.47%22 x2=%224.596%22 y1=%2214.363%22 y2=%223.397%22 xlink:href=%22%23a%22 gradientUnits=%22userSpaceOnUse%22/%3E %3C/defs%3E %3Cpath fill=%22url%28%23b%29%22 stroke=%22%237cb5d1%22 stroke-width=%22.99992%22 d=%22M8.103 1.146l2.175 4.408 4.864.707-3.52 3.431.831 4.845-4.351-2.287-4.351 2.287.831-4.845-3.52-3.431 4.864-.707z%22/%3E %3C/svg%3E")}.vectorTabs #ca-watch.icon a{background-image:url(/skins/Vector/images/watch-icon.png?e1b42);background-image:linear-gradient(transparent,transparent),url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%2216%22 height=%2216%22%3E %3Cpath fill=%22%23fff%22 stroke=%22%237cb5d1%22 stroke-width=%22.99992%22 d=%22M8.103 1.146l2.175 4.408 4.864.707-3.52 3.431.831 4.845-4.351-2.287-4.351 2.287.831-4.845-3.52-3.431 4.864-.707z%22/%3E %3C/svg%3E")}.vectorTabs #ca-unwatch.icon a:hover,.vectorTabs #ca-unwatch.icon a:focus{background-image:url(/skins/Vector/images/unwatch-icon-hl.png?c4723);background-image:linear-gradient(transparent,transparent),url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%2216%22 height=%2216%22 xmlns:xlink=%22http://www.w3.org/1999/xlink%22%3E %3Cdefs%3E %3ClinearGradient id=%22a%22%3E %3Cstop offset=%220%22 stop-color=%22%23c2edff%22/%3E %3Cstop offset=%22.5%22 stop-color=%22%2368bdff%22/%3E %3Cstop offset=%221%22 stop-color=%22%23fff%22/%3E %3C/linearGradient%3E %3ClinearGradient id=%22b%22 x1=%2213.47%22 x2=%224.596%22 y1=%2214.363%22 y2=%223.397%22 xlink:href=%22%23a%22 gradientUnits=%22userSpaceOnUse%22/%3E %3C/defs%3E %3Cpath fill=%22url%28%23b%29%22 stroke=%22%23c8b250%22 stroke-width=%22.99992%22 d=%22M8.103 1.146l2.175 4.408 4.864.707-3.52 3.431.831 4.845-4.351-2.287-4.351 2.287.831-4.845-3.52-3.431 4.864-.707z%22/%3E %3C/svg%3E")}.vectorTabs #ca-watch.icon a:hover,.vectorTabs #ca-watch.icon a:focus{background-image:url(/skins/Vector/images/watch-icon-hl.png?f4c7e);background-image:linear-gradient(transparent,transparent),url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%2216%22 height=%2216%22%3E %3Cpath fill=%22%23fff%22 stroke=%22%23c8b250%22 stroke-width=%22.99992%22 d=%22M8.103 1.146l2.175 4.408 4.864.707-3.52 3.431.831 4.845-4.351-2.287-4.351 2.287.831-4.845-3.52-3.431 4.864-.707z%22/%3E %3C/svg%3E")}.vectorTabs #ca-unwatch.icon a.loading,.vectorTabs #ca-watch.icon a.loading{background-image:url(/skins/Vector/images/watch-icon-loading.png?5cb92);background-image:linear-gradient(transparent,transparent),url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%2216%22 height=%2216%22%3E %3Cpath fill=%22%23fff%22 stroke=%22%23c8ccd1%22 stroke-width=%22.99992%22 d=%22M8.103 1.146l2.175 4.408 4.864.707-3.52 3.431.831 4.845-4.351-2.287-4.351 2.287.831-4.845-3.52-3.431 4.864-.707z%22/%3E %3C/svg%3E");-webkit-animation:rotate 700ms infinite linear;-moz-animation:rotate 700ms infinite linear;animation:rotate 700ms infinite linear;outline:0;cursor:default;pointer-events:none;background-position:50% 60%;-webkit-transform-origin:50% 57%;transform-origin:50% 57%}.vectorTabs #ca-unwatch.icon a span,.vectorTabs #ca-watch.icon a span{display:none}#mw-navigation h2{position:absolute;top:-9999px}.mw-jump-link:not(:focus){display:block;position:absolute !important;clip:rect(1px,1px,1px,1px);width:1px;height:1px;margin:-1px;border:0;padding:0;overflow:hidden}#mw-page-base{height:5em;background-position:bottom left;background-repeat:repeat-x;background-image:url(/skins/Vector/images/page-fade.png?1d168);background-color:#f6f6f6;background-image:-webkit-linear-gradient(top,#ffffff 50%,#f6f6f6 100%);background-image:-moz-linear-gradient(top,#ffffff 50%,#f6f6f6 100%);background-image:linear-gradient(#ffffff 50%,#f6f6f6 100%);background-color:#ffffff}#mw-head-base{margin-top:-5em;margin-left:10em;height:5em}#mw-head{position:absolute;top:0;right:0;width:100%}#left-navigation{float:left;margin-left:10em;margin-top:2.5em;margin-bottom:-2.5em}#right-navigation{float:right;margin-top:2.5em}#p-logo{width:10em;height:160px}#p-logo a{display:block;width:10em;height:160px;background-repeat:no-repeat;background-position:center center;text-decoration:none}#mw-panel{font-size:inherit;position:absolute;top:0;width:10em;left:0}#mw-panel .portal{margin:0 0.6em 0 0.7em;padding:0.25em 0;direction:ltr;background-position:top left;background-repeat:no-repeat}#mw-panel .portal h3{font-size:0.75em;color:#444444;font-weight:normal;margin:0.5em 0 0 0.66666667em;padding:0.25em 0;cursor:default;border:0}#mw-panel .portal .body{margin-left:0.5em;padding-top:0;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIwAAAABCAAAAAAphRnkAAAAJ0lEQVQIW7XFsQEAIAyAMPD/b7uLWz8wS5youFW1UREfiIpH1Q2VBz7fGPS1dOGeAAAAAElFTkSuQmCC);background-image:url(/skins/Vector/images/portal-break.png?3ea1b)!ie;background-repeat:no-repeat}#mw-panel .portal .body ul{list-style:none none;margin:0;padding:0.3em 0 0 0}#mw-panel .portal .body li{line-height:1.125em;margin:0;padding:0.25em 0;font-size:0.75em;word-wrap:break-word}#mw-panel .portal .body li a{color:#0645ad}#mw-panel .portal .body li a:visited{color:#0b0080}#mw-panel #p-logo + .portal{background-image:none;margin-top:1em}#mw-panel #p-logo + .portal h3{display:none}#mw-panel #p-logo + .portal .body{background-image:none;margin-left:0.5em}#footer{margin-left:10em;margin-top:0;padding:0.75em;direction:ltr}#footer ul{list-style-type:none;list-style-image:none;margin:0;padding:0}#footer ul li{color:#222;margin:0;padding:0;padding-top:0.5em;padding-bottom:0.5em;font-size:0.7em}#footer #footer-icons{float:right}#footer #footer-icons li{float:left;margin-left:0.5em;line-height:2em;text-align:right}#footer #footer-info li{line-height:1.4em}#footer #footer-places li{float:left;margin-right:1em;line-height:2em}.mw-parser-output .external{background-position:center right;background-repeat:no-repeat;background-image:url(/skins/Vector/images/external-link-ltr-icon.png?325de);background-image:linear-gradient(transparent,transparent),url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%2212%22 height=%2212%22%3E %3Cpath fill=%22%23fff%22 stroke=%22%2336c%22 d=%22M1.5 4.518h5.982V10.5H1.5z%22/%3E %3Cpath fill=%22%2336c%22 d=%22M5.765 1H11v5.39L9.427 7.937l-1.31-1.31L5.393 9.35l-2.69-2.688 2.81-2.808L4.2 2.544z%22/%3E %3Cpath fill=%22%23fff%22 d=%22M9.995 2.004l.022 4.885L8.2 5.07 5.32 7.95 4.09 6.723l2.882-2.88-1.85-1.852z%22/%3E %3C/svg%3E");padding-right:13px}}@media screen and (min-width:982px){.mw-body,#mw-head-base,#left-navigation,#footer{margin-left:11em}.mw-body{padding:1.25em 1.5em 1.5em 1.5em}#footer{padding:1.25em}#mw-panel{padding-left:0.5em}#p-search{margin-right:1em}#p-personal{right:1em}}@media print{.toc,body{padding:10px;font-family:'Linux Libertine','Georgia','Times',serif}.printfooter,#footer,.thumb,table,ol,dl,ul,h3,h4,h5,h6{font-family:sans-serif}img{font-family:'Linux Libertine','Georgia','Times',serif}a{border-bottom:1px solid #aaa}.firstHeading{font-size:25pt;line-height:28pt;margin-bottom:20px;padding-bottom:5px}.firstHeading,h2{overflow:hidden;border-bottom:2px solid #000000}h3,h4,h5,h6{margin:30px 0 0}h2,h3,h4,h5,h6{padding:0;position:relative}h2{font-size:18pt;line-height:24pt;margin-bottom:0.25em}h3{font-size:13pt;line-height:20pt}h4,h5,h6{font-size:10pt;line-height:15pt}p{font-size:10pt;line-height:16pt;margin-top:5px;text-align:justify}p:before{content:'';display:block;overflow:hidden;width:120pt}blockquote{border-left:2px solid #000000;padding-left:20px}ol,ul{margin:10px 0 0 1.6em;padding:0}ol li,ul li{padding:2px 0;font-size:10pt}table ol li,table ul li{font-size:inherit}.toc{page-break-before:avoid;page-break-after:avoid;background:none;border:0;display:table}.toc a{border:0;font-weight:normal}.toc > ul > li{margin-bottom:4px;font-weight:bold}.toc ul{margin:0;list-style:none}.toc ul ul{padding-left:30px}.toc li.toclevel-1 > a{font-weight:bold;font-size:10pt}.mw-jump-link,.toc .tocnumber{display:none}.printfooter{margin-top:10px;border-top:3px solid #000000;padding-top:10px;font-size:10pt;clear:both}#footer{margin-top:12px;border-top:1px solid #eeeeee;padding-top:5px}#footer-info{margin:0;padding:0}#footer-info li{color:#999;list-style:none;display:block;padding-bottom:10px;font-size:10pt}#footer-info li a{color:#999 !important}#footer-info-lastmod{color:#000000;font-size:12pt;font-weight:bold}}
SebastianKazan (talk) 06:44, 8 July 2019 (UTC)
From all the evidence you've given us, I can only conclude that you're server is very poorly configured:
  • mbstring is somehow misconfigured. Fixing that could solve a lot.
  • You're getting CSS when you should be getting Javascript.
The load.php url you posted works on my wikis by giving me JS. On yours it serves CSS. (You may have used the wrong URL, though, so please ensure that you pasted load.php?debug=false&lang=en&modules=startup&only=scripts&skin=vector and not load.php?debug=false&lang=en&modules=startup&only=styles&skin=vector.)
Could you verify the mbstring setting by putting a file named tmp.php in your wiki root with the contents:
<?php
phpinfo();
and then pasting the result of the mbstring section here?
On my system, it looks like this:
mbstring section
== mbstring ==
Multibyte Support enabled
Multibyte string engine libmbfl
HTTP input encoding translation disabled
libmbfl version 1.3.2
oniguruma version 6.9.0
mbstring extension makes use of "streamable kanji code filter and converter", which is distributed under the GNU Lesser General Public License version 2.1.
Multibyte (japanese) regex support enabled
Multibyte regex (oniguruma) backtrack check On
Multibyte regex (oniguruma) version 6.9.0
Directive Local Value Master Value
mbstring.detect_order no value no value
mbstring.encoding_translation Off Off
mbstring.func_overload 0 0
mbstring.http_input no value no value
mbstring.http_output no value no value
mbstring.http_output_conv_mimetypes ^(text/|application/xhtml\+xml) ^(text/|application/xhtml\+xml)
mbstring.internal_encoding no value no value
mbstring.language neutral neutral
mbstring.regex_stack_limit 100000 100000
mbstring.strict_detection Off Off
mbstring.substitute_character no value no value
MarkAHershberger(talk) 18:41, 8 July 2019 (UTC)
Hello Mark,
indeed, i posted the wrong source (styles&skin=vector).
Here is the (scripts&vector) source:
Extended content
The mbstring configuration looks like this:
Extended content
==mbstring==
Multibyte Support enabled
Multibyte string engine libmbfl
HTTP input encoding translation disabled
libmbfl version 1.3.2
oniguruma version 6.3.0
mbstring extension makes use of "streamable kanji code filter and converter", which is distributed under the GNU Lesser General Public License version 2.1.
Multibyte (japanese) regex support enabled
Multibyte regex (oniguruma) version 6.3.0
Directive Local Value Master Value
mbstring.detect_order no value no value
mbstring.encoding_translation Off Off
mbstring.func_overload 0 0
mbstring.http_input no value no value
mbstring.http_output no value no value
mbstring.http_output_conv_mimetypes ^(text/|application/xhtml\+xml) ^(text/|application/xhtml\+xml)
mbstring.internal_encoding no value no value
mbstring.language neutral neutral
mbstring.strict_detection Off Off
mbstring.substitute_character no value no value
SebastianKazan (talk) 12:06, 9 July 2019 (UTC)
It seems like I get the load.php error with styles&skin=vector, when the layout is totally smashed and the script&skin=vector when it looks "normal".. SebastianKazan (talk) 12:08, 9 July 2019 (UTC)
If you are getting problems intermittently, then it looks like your wiki is being served by different configurations.
Please present this problem to your hosting provider and let them know that you are intermittently getting the error about mbstring and you want to know why since it is causing problems with your site. MarkAHershberger(talk) 19:11, 9 July 2019 (UTC)
Thank you, I will check this today. And do you think this also causes the layout problems? SebastianKazan (talk) 07:26, 10 July 2019 (UTC)
It could well cause an intermittent layout problem, yes. MarkAHershberger(talk) 16:40, 10 July 2019 (UTC)
Hello Mark,
I contacted my server company and they did a PHP update to 7.3. I am still testing, but since 20+ refreshs it seems to be working and not producing errors...
I pray ;)
Many many thanks for your help! SebastianKazan (talk) 07:19, 11 July 2019 (UTC)

wiki on DVD?

Is there a way to move an existing wiki to removable storage and have it work like a wiki does online?


We have a wiki that is becoming stagnant and we may have to take it down. We would like to make the information collected in it available later on removanle storag.


Kirby 2600:1700:DE20:8E30:21F:5BFF:FE36:A4C0 (talk) 13:36, 1 July 2019 (UTC)

See Manual:Wiki on a stick, and maybe USB MediaWiki too. AhmadF.Cheema (talk) 15:04, 1 July 2019 (UTC)
We want it to be read only. Not a full operating version of the wiki.
Kirby 2600:1700:DE20:8E30:21F:5BFF:FE36:A4C0 (talk) 02:10, 2 July 2019 (UTC)
If you want an exact read copy of the website, the only way I know is HTTrack Website Copier. AhmadF.Cheema (talk) 04:31, 2 July 2019 (UTC)

Preventing translation in sidebar menu

I have added to the sidebar menu a link which I named categories:

https://example.com/index.php?title=%D7%9E%D7%99%D7%95%D7%97%D7%93:%D7%A7%D7%98%D7%92%D7%95%D7%A8%D7%99%D7%95%D7%AA%7CCategories

Instead "categories" in English (just as in the end of the link above) I get the Hebrew "קטגוריות" (as this an RTL-Hebrew website), although I need the English "categories".

This is likely due to machine-translation.

Is there a way (maybe visa MediaWiki syntax) to escape the categories word in the link so it won't be translated by the machine-translation? 49.230.62.64 (talk) 18:19, 1 July 2019 (UTC)

I use MediaWiki 1.32.0.
Also, related topic: Project:Support desk/Flow/2019/07#h-Adding_a_CSS_selector_for_a_Sidebar_menu_link-2019-07-01T09:50:00.000Z 49.230.62.64 (talk) 14:35, 2 July 2019 (UTC)
See my answer on the other topic. MarkAHershberger(talk) 16:55, 2 July 2019 (UTC)

About mediawiki's premium support

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


I would like to know if there is premium support for the mediawiki platform.

about:


1) Is it a company (partner)?

2) Are they freelancer?

3) Are users similar to the freelancer but authorized from the mediawiki?

4) I guess most of them are project developers?

5) Something important. Is there any membership or similar to being a patreon in mediawiki?

6) Sometimes in wikipedia I see that they need monetary help for the project to go ahead. If I support the community, would I have any benefit of receiving rapid assistance as soon as a problem arises for free or with a payment with a lower price? Senseidb (talk) 04:47, 2 July 2019 (UTC)

See Project:About and Professional development and consulting. Malyacko (talk) 06:29, 2 July 2019 (UTC)
Ok thank you. Senseidb (talk) 14:23, 2 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

editing the sidebar

I browsed to my local MediaWiki setup

http://localhost/index.php/MediaWiki:Sidebar

It displays the content:

  • navigation
    • mainpage|mainpage-description
    • recentchanges-url|recentchanges
    • randompage-url|randompage
    • helppage|help-mediawiki
  • SEARCH
  • TOOLBOX
  • LANGUAGES


But I am not able to edit to add new link,.


How to get the permission to edit this? This is installed by me. for my purpose.

current LocalSettings.php related to permission is like

$wgGroupPermissions['*']['info'] = true;

$wgGroupPermissions['*']['read'] = true;

$wgGroupPermissions['*']['edit'] = true;

$wgGroupPermissions['group']['right'] = true



Paperlessnow (talk) 08:23, 2 July 2019 (UTC)

Your user group needs to have the 'editinterface' right to edit the MediaWiki namespace, by default that is the sysop group.
Look at your Special:Preferences, are you part of the administrator/sysop user group?
If not, and you're also not part of the Bureaucrat group which allows adding users to different user groups, then see Manual:CreateAndPromote.php. AhmadF.Cheema (talk) 09:11, 2 July 2019 (UTC)

Installation trouble - AbstractContent

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


Hi!

I am trying to install the latest version of MediaWiki at my host UnoEuro.

But near the end of the installation script, this error appears:

Fatal error:  Class 'AbstractContent' not found in .../public_html/includes/content/TextContent.php on line 37

The only option is then to restart the installation, but the same error shows up. I have tried deleting the TextContent.php and reuploading it, but without any luck.

Any idea on how to continue?

Thanks! Balistarius1783 (talk) 08:37, 2 July 2019 (UTC)

The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Upload MediaWiki\Revision\IncompleteRevisionException from line 420 of ..\includes\Revision\RevisionStore.php: sha1 field must not be !

I get this error when I try to upload a new version of an existing file.

The orginal / current file on the wiki was uploaded back in September 2018. Since then, the wiki has been upgraded and migrated to a new server.

Currently, we are using MW 1.32.

Now, If I upload a new version of the same file, i first get a couple of warnings:

  • A file of this name has been previously uploaded and subsequently deleted. You should check the deletion log before proceeding to upload it again.
  • A file identical to this file (File:file.pdf) has previously been deleted. You should check that file's deletion history before proceeding to re-upload it.

I then click the "Ignore warning and save file anyway" button. This results in the error:

[12911fa08d4b434347f272f4] /wiki/index.php?title=Special:Upload MediaWiki\Revision\IncompleteRevisionException from line 420 of ...\includes\Revision\RevisionStore.php: sha1 field must not be ''
Backtrace:

#0 ...\includes\Revision\RevisionStore.php(473): MediaWiki\Revision\RevisionStore->failOnEmpty(string, string)
#1 ...\includes\Revision.php(1136): MediaWiki\Revision\RevisionStore->insertRevisionOn(MediaWiki\Revision\MutableRevisionRecord, Wikimedia\Rdbms\DatabaseMysqli)
#2 ...\includes\filerepo\file\LocalFile.php(1674): Revision->insertOn(Wikimedia\Rdbms\DatabaseMysqli)
#3 ...\includes\filerepo\file\LocalFile.php(1369): LocalFile->recordUpload2(string, string, boolean, array, string, User, array, boolean)
#4 ...\includes\upload\UploadBase.php(868): LocalFile->upload(string, string, boolean, integer, array, boolean, User, array)
#5 ...\includes\specials\SpecialUpload.php(567): UploadBase->performUpload(string, boolean, boolean, User, array)
#6 ...\includes\specials\SpecialUpload.php(207): SpecialUpload->processUpload()
#7 ...\includes\specialpage\SpecialPage.php(569): SpecialUpload->execute(NULL)
#8 ...\includes\specialpage\SpecialPageFactory.php(568): SpecialPage->run(NULL)
#9 ...\includes\MediaWiki.php(288): MediaWiki\Special\SpecialPageFactory->executePath(Title, RequestContext)
#10 ...\includes\MediaWiki.php(860): MediaWiki->performRequest()
#11 ...\includes\MediaWiki.php(517): MediaWiki->main()
#12 ...\index.php(42): MediaWiki->run()
#13 {main}

From other posts, I found that running the maintenance script populateRevisionSha1.php should rebuild the sha1 field content, but if I look into the revision table of the wiki, no rows has an empty sha1 field:

SELECT * FROM wiki_revision WHERE rev_sha1 = '' or rev_sha1 = null;
0 row(s) returned.

And, just to verify:

SELECT * FROM wiki_revision WHERE rev_sha1 <> '';</code>
1000 row(s) returned.

Same goes for the archive table:

SELECT * FROM wiki_archive WHERE ar_sha1 = '' or ar_sha1 = null;
0 row(s) returned.

I have tried running populateRevisionSha1.php with the --force option but to no avail.

Also, This does not happen if I upload a new file and update that new file with an even newer one.

Any ideas? Bdipdc (talk) 09:50, 2 July 2019 (UTC)

There is extensive information on this task. Since you've already run populateRevisionSha1.php --force, have you tried any of the other things there? MarkAHershberger(talk) 18:11, 2 July 2019 (UTC)
I couldnt find anything really useful on the page that you refer to. It's my content_sha1 field that is empty on all documents.
Do you know if it would be possible to fill out the content_sha1 field with e.g. a "0" (0x30) or another random value, so that the field is non-empty (but content not valid) and that will work? Bdipdc (talk) 09:42, 3 July 2019 (UTC)
I haven't tried anything with this myself, so go ahead and try, but make sure you can roll back any changes if you need to.
It looks like there is some activity on this problem, though: Update populateRevisionSha1.php to run over the content table. MarkAHershberger(talk) 17:12, 3 July 2019 (UTC)

Footnote template

I have a MediaWiki website which is extensionless; I don't use any extensions whatsoever.

I need to add up to 5 footnotes to some articles. I know it might seem wired but I am not going to install Cite or any other extension.

Yet I still need to use up to 5 (manually-sorted) footnotes, and for that I can make:

template:1 with <sup>'''1'''</sup>

template:2 with <sup>'''2'''</sup>

template:3 with <sup>'''3'''</sup>

template:4 with <sup>'''4'''</sup>

template:5 with <sup>'''5'''</sup>

I could use these as footnote 1,2,3,4,5


But, I prefer just one template to which I could pass an argument like

template:footnote(1) or template:footnote(2), or template:footnote(3), or template:footnote(4), or template:footnote(5)

How could I use just one template with 5 arguments instead 5 different templates? 49.230.62.64 (talk) 10:30, 2 July 2019 (UTC)

Which exact MediaWiki version is this about? Malyacko (talk) 10:34, 2 July 2019 (UTC)
@Malyacko 1.32.0. 49.230.62.64 (talk) 14:33, 2 July 2019 (UTC)
1.32.0 means that your MediaWiki website is not "extensionless" anyway, except for if you manually uninstalled the default extensions... Malyacko (talk) 20:49, 2 July 2019 (UTC)
Sorry, by "extensionless" I meant without "external extensions". 49.230.62.64 (talk) 22:28, 2 July 2019 (UTC)
Please delete this question. It was published bad and I should republish it. 49.230.62.64 (talk) 13:15, 3 July 2019 (UTC)

JavaScript works in Chrome console but not in Common.js

In MediaWiki 1.32.0 the following code works for me fine in (latest) Chrome console but not in Common.js:
document.querySelectorAll([
"#n-Special-pages",
"#n-Categories",
"#n-Webpages-to-create",
"#n-CSS",
"#n-JS1",
"#n-JS2",
"#n-Edit-this-menu"
]).forEach((element) => {
element.style.display = "none";
});
Even If I wrap it in a one-second setTimeout() with an anonymous function it still doesn't work:
window.setTimeout(()=>{
document.querySelectorAll([
"#n-Special-pages",
"#n-Categories",
"#n-Webpages-to-create",
"#n-CSS",
"#n-JS1",
"#n-JS2",
"#n-Edit-this-menu"
]).forEach((element) => {
element.style.display = "none";
});
}, 1000); 49.230.62.64 (talk) 00:54, 3 July 2019 (UTC)
Note that the querySelectorAll does not support an Array. This is currently working by accident, and will likely fail in the future. This method requires a valid CSS selector string. Such string can take multiple selectors separated by a comma, like so: querySelector("#foo, bar"). Just like in CSS: #foo, #bar { display: none }. It should be a single string, not an array of strings.
This also brings me to a perhaps alternate solution to your problem, which is to remove this JavaScript code entirely from your Common.js page, and instead use Common.css instead. This would be much more performant (save Internet bandwidth and battery power), and also less annoying for users (always invisible, instead of first visible and then invisible). Krinkle (talk) 20:06, 4 July 2019 (UTC)
Righteously formatted:
window.setTimeout(()=>{
document.querySelectorAll([
"#n-Special-pages",
"#n-Categories",
"#n-Webpages-to-create",
"#n-CSS",
"#n-JS1",
"#n-JS2",
"#n-Edit-this-menu"
]).forEach((element) => {
element.style.display = "none"
;}
);}, 1000); 49.230.62.64 (talk) 01:19, 3 July 2019 (UTC)
does this work in MediaWiki 1.31? MarkAHershberger(talk) 01:25, 3 July 2019 (UTC)
The timeout may not be sufficient if the DOM is not ready when you execute the document.querySelectorAll.
Wrap your code in:
$(function() {
// Your code here
});
Ciencia Al Poder (talk) 13:53, 3 July 2019 (UTC)
@Ciencia Al Poder by principle I avoid using jQuery (of course this principle can have exceptions).
How will you do this with vanilla, if it's even possible? 49.230.62.64 (talk) 14:44, 3 July 2019 (UTC)
Use the DOMContentLoaded event
https://developer.mozilla.org/en-US/docs/Web/API/Window/DOMContentLoaded_event Ciencia Al Poder (talk) 20:58, 3 July 2019 (UTC)
@Ciencia Al Poder sadly both ways didn't work. Also I remember I never had a case when setTimeout didn't work and DOMContentLoaded did. There must be another problem. 49.230.62.64 (talk) 01:02, 4 July 2019 (UTC)
Feel free to ask on a JavaScript specialized forum, then, since this doesn't seem to be a MediaWiki problem. Ciencia Al Poder (talk) 09:12, 4 July 2019 (UTC)
I tell you with all sincerity that to me it does seem MediaWiki 1.32.0 related because I cannot explain why the code works in browser console but not in Common.js... 49.230.58.174 (talk) 15:26, 4 July 2019 (UTC)
Even if it is caused by the JS in MW 1.32, most of us aren't JS experts here. A developer like @Krinkle might know, but most of us here in the support desk won't have a clue. MarkAHershberger(talk) 18:06, 4 July 2019 (UTC)
The two solutions offered by @Ciencia are both correct ways to ensure your customisation logic waits until the page has finished loading. This is the standard and only supported way to run such logic, and always has been (since 2011). It has not changed in recent releases.
Given that it does not appear to solve the problem you are experiencing, it is most likely that the problem is not related to parts of the page created by MediaWiki, as those will be ready by then, no exception.
The code pasted at the start of this thread does not appear to make sure of anything MediaWiki-related. It selects elements on the page using plain DOM JavaScript methods, with target IDs that are custom to the local wiki. If these elements don't exist for some reason, it is likely because they are not created by anything on the page. Or maybe you have other customisation code (like a gadget, or something else in your Common.js file) that is creating those links, in which case this is a question of "How do I select an element created by me in JavaScript", for which StackOverflow might be a better place to ask and learn how to do that.
Most likely, your Common.js file is experiencing a "race condition", which means it worked by coincidence in the past and now not any more. (E.g. two asynchronous code paths that are in need for better organising so that they run in the right order). Krinkle (talk) 20:03, 4 July 2019 (UTC)
sorry.. nevermind. wrong topic. Utini (talk) 20:07, 4 July 2019 (UTC)

Finding a Media Wiki Developer

How can I find a Media Wiki developer to help with my project?

216.14.2.214 (talk) 08:56, 3 July 2019 (UTC)
Hard to say without way clearer information. There is for example https://discourse-mediawiki.wmflabs.org/, there is also Professional development and consulting. Malyacko (talk) 09:11, 3 July 2019 (UTC)

Log-In and PDF - connection disrupted in LAN network

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


I am just setting up a MedikaWiki in a LAN network at my workplace.

So far the wiki works quite well on my localhost machine, but if i want to login from another computer in the network (which has access to the MediaWiki through http://xxx.xxx.xx.xx/wiki/Index.php) it just suspends and results in a connection disruption.

The general pages load perfectly fine, but the login leads to this connection error. If i switch to another page in the wiki i suddenly am logged in.

And furthermore i use the PDFEmbed-extension for pdf-integration but the PDF files are also not loading if i access a page from another computer.


Does anybody have an idea what is missing or what scripts need to be changed? Seehausen (talk) 12:07, 3 July 2019 (UTC)

Network policies may be preventing access. For instance, using cookies on an website that you access via an IP address could well be flaky. $wgServer in your LocalSettings.php is probably part of the problem. MarkAHershberger(talk) 17:25, 3 July 2019 (UTC)
I had similar issue. The Wiki worked on other computers in the LAN quite well except the Log-In (and some intergrated files e.g. Pdf files, which didn´t load).
I think if there were network policy problems i couldn´t even access the Wiki-pages in general on other computers?
And where would i change the cookie settings? 134.130.74.73 (talk) 10:07, 4 July 2019 (UTC)
I'm not sure. I would recommend that you talk to your local help desk since they would have more knowledge about that.
But here is a hint of where to look for cookie policies on windows. MarkAHershberger(talk) 18:18, 4 July 2019 (UTC)
Hey @MarkAHershberger
Thanks a lot for your replies. You were right with the $wgServer settings. I forgot the " https:// " before the IP address. Now also the files load correctly and the Log-In´s work well! Seehausen (talk) 10:39, 8 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Manual footnotes template

I have a MediaWiki 1.32.0 website with no external extensions whatsoever - I don't want to install any extension.

I need to add some manually-sorted footnotes to some articles and for that I can create:

template:1 with <sup>'''1'''</sup>

template:2 with <sup>'''2'''</sup>

template:3 with <sup>'''3'''</sup>

template:4 with <sup>'''4'''</sup>

template:5 with <sup>'''5'''</sup>

I could use these as footnotes 1,2,3,4,5

Instead creating five different templates, how could I create just one template to which I could pass an argument as a 1-5 number? 49.230.62.64 (talk) 13:17, 3 July 2019 (UTC)

I found this template on an old, deleted revision on meta:
<span class="reference"><sup id="ref_{{{1}}}" class="plainlinksneverexpand">[{{fullurl:{{FULLPAGENAME}}}}#endnote_{{{1}}}]</sup></span>
MarkAHershberger(talk) 17:34, 3 July 2019 (UTC)
@MarkAHershberger if you have one, please share an explanation of what is going on there.
I personally would like to know how can different numbers (1,2,3,4,5 and so forth) could be used instead the 1 there. 49.230.58.174 (talk) 15:34, 4 July 2019 (UTC)
The {{{1}}} will use the first argument passed to the template.
For instance, I've created two templates in my wiki. Template:Foot and Template:Footnote. Template:Foot contains
<span class="reference"><sup id="ref_{{{1}}}" class="plainlinks">[{{fullurl:{{FULLPAGENAME}}}}#endnote_{{{1}}}]</sup></span>
While Template:Footnote contains
<span id="endnote_{{{1}}}" class="plainlinks">[[{{fullurl:{{FULLPAGENAME}}}}#ref_{{{1}}} {{{1}}}]].</span>
So I can just put
This is text followed by a footnote{{Foot|1}}
.
in my text and then, in the footnotes section of my page
{{footnote|1}}This is the footnote that links back to the original text.
MarkAHershberger(talk) 18:03, 4 July 2019 (UTC)
Thanks! 49.230.58.174 (talk) 10:41, 5 July 2019 (UTC)
@MarkAHershberger I tried to read the codes several times but I miss what the Wiki syntax is doing in these templates. I hope you'd like to explain only the Wiki syntax part of these templates. 182.232.0.101 (talk) 19:51, 8 July 2019 (UTC)
Which specific items do you not understand? MarkAHershberger(talk) 21:08, 8 July 2019 (UTC)

Mediawiki on a Windows Server 2016 Machine with IIS and LDAP or Kerberos Auth

Dear Sirs,


i am new to the topic of setting up a Wiki and my Task is to set up a Wiki which then will only be available to someone in out Intranet if they Authenticate through the Active Directory. Alternatively we can Use Kerberos as a Auth Method. Now i googled all over the place and what i come across is the out of date version of an extension not supporting the new Versions of Mediawiki anymore. I have Mediawiki running on a Windows Server 2016 Machine with IIS and MariaDB. It works....now i need to make it Auth through my Active directory (running on the same server for now for testing...later will be a separate server of course)


Can anyone advise :D ? 141.90.2.44 (talk) 13:25, 3 July 2019 (UTC)

If you have access to a SAML provider (e.g. many corporate Office365 users do), then you could use @Cindy.cicalese PluggableAuth + SimpleSAMLphp.
Alternatively, while I'm familiar with integrating Apache on Linux into the sort of environment that you're talking about, I'm not so sure on Windows+IIS. I think you should just have to turn on Integrated Windows Authentication and then use the LOGON_USER or REMOTE_USER header with the Auth_remoteuser extension. MarkAHershberger(talk) 17:52, 3 July 2019 (UTC)
You may also be able to use Extension:PluggableAuth with Extension:OpenID Connect. See Extension:OpenID_Connect#Example:_Using_it_against_Azure_ADFS. Cindy.cicalese (talk) 18:05, 3 July 2019 (UTC)
There is also the LDAP hub that you might want to look at. Osnard (talk) 07:06, 4 July 2019 (UTC)

How to add a body-class for anonymous users?

I need to add a body CSS class that will be available only for anonymous users. This will use me to hide some menu links for anonymous users so that only registered users could use them.

How could I add such a class? 49.230.62.64 (talk) 04:17, 4 July 2019 (UTC)

See Project:Support desk/Flow/2018/02#h-Anon_group_CSS-2018-02-23T17:33:00.000Z. If by "menu" you mean specifically the sidebar, then see Project:Support desk/Flow/2019/06#h-How_to_hide_Sidebar_Menu_links_for_anonymous_users?-2019-06-30T10:07:00.000Z. AhmadF.Cheema (talk) 08:52, 4 July 2019 (UTC)
You could add the following to your LocalSettings.php:
$wgHooks['OutputPageBodyAttributes'][] = function ( OutputPage $out, Skin $skin, &$bodyAttrs ) {
   if ( $out->getUser()->isAnon() ) {
      $bodyAttrs['class'] .= ' not-logged-in'; // Note the leading space character.
   }
};
Sam Wilson 10:56, 4 July 2019 (UTC)
Thanks @Samwilson sadly it doesn't work for me in 1.32.0
@AhmadF.Cheema I opened the second topic you mentioned; I followed the instructions there and opened a third topic on a wired JS problem:
Project:Support desk/Flow/2019/07#h-JavaScript_works_in_Chrome_console_but_not_in_Common.js-2019-07-03T00:54:00.000Z 49.230.58.174 (talk) 14:15, 4 July 2019 (UTC)
What error do you get with 1.32.0? It works for me on a vanilla installation. Sam Wilson 07:42, 5 July 2019 (UTC)
@Samwilson sadly as of the moment I cannot debug PHP... 49.230.58.174 (talk) 10:46, 5 July 2019 (UTC)
But in what way does it not work? Sam Wilson 10:49, 5 July 2019 (UTC)
@Samwilson I added the codepiece to the end of LocalSettings.php, saved the file, went to the website, refreshed by CTRL+SHIFT+R, checked the DOM but still didn't see the body class named `.not-logged-in`. 49.230.58.174 (talk) 10:57, 5 July 2019 (UTC)
Hm, tricky. And you are sure you weren't logged in and that all relevant caches were cleared? Did LocalSettings.php save correctly? Is your site publicly visible (could I have a look)? Sam Wilson 11:22, 5 July 2019 (UTC)
@Samwilson Sorry, I fell there again, I am used to work only with one browser and in a period when I am hard to think clearly.
But it was my own fault.
I now checked from another browser and indeed I see it in DOM.
I thank you and beg your pardon. 49.230.58.174 (talk) 11:26, 5 July 2019 (UTC)
Oh good, I'm glad it wasn't some strange bug. And no worries at all, we definitely all make exactly that sort of mistake sometimes! :-) Sam Wilson 12:12, 5 July 2019 (UTC)

Cannot log in when using MediaWiki\Session\BotPasswordSessionProvider sessions when use bot

My final goal is to use bot read the wiki source content, just like

http://www.example.com/api.php?action=query&titles=test&format=json&redirects=true&prop=revisions&rvprop=content&rvlimit=1


this is my proccess

  1. create a bot account
  2. take this page as example and add more code
  3. doing the same thing on PHP

the code runs perfect on python, I got content by title correctly, but when it executed on PHP I got error message below:


array(2) {

  ["warnings"]=>

  array(1) {

    ["main"]=>

    array(1) {

      ["*"]=>

      string(75) "Unrecognized parameters: 'titles', 'redirects', 'prop', 'rvprop', 'rvlimit'"

    }

  }

  ["login"]=>

  array(2) {

    ["result"]=>

    string(7) "Aborted"

    ["reason"]=>

    string(78) "Cannot log in when using MediaWiki\Session\BotPasswordSessionProvider sessions"

  }

}


don't know how to fix it. Chan15tw (talk) 09:40, 4 July 2019 (UTC)

The error makes it look like it is confusing your two calls to curl_exec. You are not ever using CURLOPT_POST to handle the login. So that may be one place to look. MarkAHershberger(talk) 20:10, 4 July 2019 (UTC)

Error: 1191 Can't find FULLTEXT index matching the column list (localhost)

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


Hello Support desk,

I use "ApacheFriends XAMPP Version 7.3.5".

Here's a screenshot of my Special:Version page.
[6645e4370bd5eaab3ca6a8e7] /tstwiki/index.php?title=Sp%C3%A9cial%3ARecherche&search=aled&go=Continuer Wikimedia\Rdbms\DBQueryError from line 1506 of C:\xampp\htdocs\tstwiki\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 page_id,page_namespace,page_title FROM `page`,`searchindex` WHERE (page_id=si_page) AND ( MATCH(si_title) AGAINST('+aled ' IN BOOLEAN MODE) ) AND page_namespace = '0' ORDER BY MATCH(si_title) AGAINST('+aled ' IN NATURAL LANGUAGE MODE) DESC LIMIT 21
Function: SearchMySQL::searchInternal
Error: 1191 Can't find FULLTEXT index matching the column list (localhost)

Backtrace:

#0 C:\xampp\htdocs\tstwiki\includes\libs\rdbms\database\Database.php(1476): Wikimedia\Rdbms\Database->makeQueryException(string, integer, string, string)
#1 C:\xampp\htdocs\tstwiki\includes\libs\rdbms\database\Database.php(1236): Wikimedia\Rdbms\Database->reportQueryError(string, integer, string, string, boolean)
#2 C:\xampp\htdocs\tstwiki\includes\libs\rdbms\database\Database.php(1703): Wikimedia\Rdbms\Database->query(string, string)
#3 C:\xampp\htdocs\tstwiki\includes\search\SearchMySQL.php(191): Wikimedia\Rdbms\Database->select(array, array, array, string, array, array)
#4 C:\xampp\htdocs\tstwiki\includes\search\SearchMySQL.php(178): SearchMySQL->searchInternal(string, boolean)
#5 C:\xampp\htdocs\tstwiki\includes\search\SearchDatabase.php(69): SearchMySQL->doSearchTitleInDB(string)
#6 C:\xampp\htdocs\tstwiki\includes\search\SearchEngine.php(140): SearchDatabase->doSearchTitle(string)
#7 C:\xampp\htdocs\tstwiki\includes\search\SearchEngine.php(169): SearchEngine->{closure}()
#8 C:\xampp\htdocs\tstwiki\includes\search\SearchEngine.php(141): SearchEngine->maybePaginate(Closure)
#9 C:\xampp\htdocs\tstwiki\includes\specials\SpecialSearch.php(341): SearchEngine->searchTitle(string)
#10 C:\xampp\htdocs\tstwiki\includes\specials\SpecialSearch.php(190): SpecialSearch->showResults(string)
#11 C:\xampp\htdocs\tstwiki\includes\specialpage\SpecialPage.php(569): SpecialSearch->execute(NULL)
#12 C:\xampp\htdocs\tstwiki\includes\specialpage\SpecialPageFactory.php(568): SpecialPage->run(NULL)
#13 C:\xampp\htdocs\tstwiki\includes\MediaWiki.php(288): MediaWiki\Special\SpecialPageFactory->executePath(Title, RequestContext)
#14 C:\xampp\htdocs\tstwiki\includes\MediaWiki.php(860): MediaWiki->performRequest()
#15 C:\xampp\htdocs\tstwiki\includes\MediaWiki.php(517): MediaWiki->main()
#16 C:\xampp\htdocs\tstwiki\index.php(42): MediaWiki->run()
#17 {main}

Lilitst (talk) 11:24, 4 July 2019 (UTC)
Did you run update.php? It looks like an index is missing from your DB schema. MarkAHershberger(talk) 19:47, 4 July 2019 (UTC)
@MarkAHershbergerYes. The error still appears.
I don't know if it's an interesting fact, but the database was originally imported from a bitnami install. Lilitst (talk) 10:05, 5 July 2019 (UTC)
If you can execute SQL commands, pleas try the following:
show create table searchindex;
and paste the output here. MarkAHershberger(talk) 14:03, 5 July 2019 (UTC)

----CREATE TABLE `searchindex` ( `si_page` int(10) unsigned NOT NULL, `si_title` varchar(255) NOT NULL DEFAULT '', `si_text` mediumtext NOT NULL, UNIQUE KEY `si_page` (`si_page`) ) ENGINE=MyISAM DEFAULT CHARSET=utf8 Lilitst (talk) 16:44, 8 July 2019 (UTC)
Try running the following two sql statements. It looks like they were missed somehow. This kind of makes me think that other indexes are missing.
CREATE FULLTEXT INDEX si_title ON searchindex (si_title);
CREATE FULLTEXT INDEX si_text ON searchindex (si_text);
MarkAHershberger(talk) 17:50, 8 July 2019 (UTC)
Thank you very much, the SQL query worked. I runned a search after that and all seemed fine. Lilitst (talk) 17:06, 9 July 2019 (UTC)
And yeah, I wonder which indexes are missing. I think it's maybe a consequence of a failed rebuilall.php.
I originally created an account here for that matter, but I'll post it in another thread. Long-story short, rebuildall.php cries about missing "Scribunto" module and throws a MWUnknownContentModelException from ContentHandler.php. Even after adding the extensions in the right folder, error still occurs. Lilitst (talk) 17:10, 9 July 2019 (UTC)
It wouldn't be a failing rebuildall.php, but a problem with update.php.
And you have to edit LocalSettings.php to tell MediaWiki to use Scribunto after putting the extension in the extensions directory. MarkAHershberger(talk) 19:01, 9 July 2019 (UTC)
I retried with the Scribunto and TemplateStyles extensions added and the rebuildall.php worked.
I did a test before these were installed and tried to do a random search on my wiki. It broke again.
With the correct extensions, the rebuild worked and search was reenabled after that.
Thanks for all your help. Lilitst (talk) 07:46, 10 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Hiding specific menu in the sidebar for unlogged users

Hi,

I work on MW 1.32. I would like to hide specific menu which is located in the Sidebar but only on the Login Page. Unfortunately, my knowledges are kinda weak and I have no idea on how to make it.

Thanks 185.126.230.6 (talk) 13:52, 4 July 2019 (UTC)

Adding something like
.mw-special-Userlogin #mw-panel {display: none}
should do it, I think. MarkAHershberger(talk) 20:29, 4 July 2019 (UTC)
Unfortunately it doesn't work, it's still visible. Hiding the entire sidebar for the login page would be enough tbh.
Thanks 185.126.230.6 (talk) 07:32, 5 July 2019 (UTC)
Probably need to set $wgAllowSiteCSSOnRestrictedPages to true. AhmadF.Cheema (talk) 09:22, 5 July 2019 (UTC)
Yes it works, thanks ! I have another question (really sorry) : Is it possible to directly be on the login page instead of home page where is written "Connection necessary" ?
Thanks 185.126.230.6 (talk) 12:19, 5 July 2019 (UTC)
The only way I can see to do that right now is to have some JS that redirects to the login page whenever that page appears. MarkAHershberger(talk) 14:17, 5 July 2019 (UTC)
There is also How can I change the landing page ... to directly go to Special:UserLogin, but it requires editing core files which is not recommended.
Also, there is a proposed patch to MediaWiki core which is supposed to include such a functionality but for some reason cannot be merged. AhmadF.Cheema (talk) 14:41, 5 July 2019 (UTC)
The patch is just out of date. It looks like it could still be merged if someone were to manually re-base it. MarkAHershberger(talk) 17:52, 5 July 2019 (UTC)
I've updated the patch... Let me see if I can get someone to re-review. MarkAHershberger(talk) 19:00, 5 July 2019 (UTC)
Thanks for every answers and sorry for the late response. I'll try solutions that you gave following the tutorial you gave. 185.126.230.6 (talk) 15:56, 10 July 2019 (UTC)

WikiCategoryTagCloud always collapsed

Hello there,

I am using the Extension WikiCategoryTagCloud, which creates a list with the Categories. Sadly the table is always collapsed which kind of ruins my layout. Is ist possible to show directly the expanded list.

The table gets from the beginning the class mw-collapsed and I would like to avoid it.


Thanks!


PD: I use the Vector skin Victorwiki82 (talk) 14:49, 4 July 2019 (UTC)

Can you link to your wiki?
Is the tagcloud CSS class at the same level as the mw-collapsed class? You should be able to use CSS on the tagcloud class to override the mw-collapsed class. MarkAHershberger(talk) 19:40, 4 July 2019 (UTC)
Hi Mark it is a private Wiki, sadly I can not link it. Victorwiki82 (talk) 13:57, 9 July 2019 (UTC)

Issues With Wiki

Hi, I'm creating a mediawiki for my work place and have very little experience of the process until now and have self-taught using the media wiki user guide. Looking for some assistance, recently the following has become an issue:


My internal links to anchors on other pages stopped working - they just load for a very long time without the page changing in the slightest (the URL occasionally does)

Image files do not update when I upload a new version of the file.

I do not have the option (despite being an administrator) to delete files - an option I was considering because of the above.


If anyone has any suggestions on how to remedy the above I'd very much appreciate it.


Thanks LizCwiki (talk) 15:08, 4 July 2019 (UTC)

Please see How to debug and, if you try things there and it doesn't work, let us know.
One quick thing to try is adding
error_reporting( -1 );
ini_set( 'display_errors', '1' );
to your LocalSettings.php and see if you get any errors reported. MarkAHershberger(talk) 19:28, 4 July 2019 (UTC)

upgraded to Mediawiki 1.33 exception error

the following error occurred after running the upgrade. This is the first time that I have encountered such an error when upgrading. Would appreciate some guidance on how to resolve this.

XR4xGx6n1OgF77FSHGANTwAAAAc] 2019-07-04 17:02:20: Fatal exception of type "Wikimedia\Rdbms\DBQueryError"

my site is at : http://danleff.net/danleffwiki/wiki/index.php?title=Main_Page

Thank you!


Danleff (talk) 17:15, 4 July 2019 (UTC)

did you run update.php? MarkAHershberger(talk) 19:23, 4 July 2019 (UTC)
could you add the following three lines to your LocalSettings.php to help with debugging the problem?
error_reporting( -1 );
ini_set( 'display_errors', '1' );
$wgDebugDumpSql = true;
MarkAHershberger(talk) 19:24, 4 July 2019 (UTC)
yes, I ran the update.php and saw no problems with upgrade. I'll add te lines and post back. Danleff (talk) 19:28, 4 July 2019 (UTC)
Now I just receive this message;
[XR6u8h06oc2nMlb3wA@aDAAAAAI] 2019-07-05 01:59:14: Fatal exception of type MWException Danleff (talk) 02:03, 5 July 2019 (UTC)
Also add the following to your LocalSettings.php:
$wgShowExceptionDetails = true;
$wgDevelopmentWarnings = true;
AhmadF.Cheema (talk) 03:16, 5 July 2019 (UTC)
here is the result when I try to load the wiki page;
Notice: "" is not a valid magic word for "customtitle" [Called from Language::getMagic in /home/danleff2/public_html/danleffwiki/wiki/languages/Language.php at line 3220] in /home/danleff2/public_html/danleffwiki/wiki/includes/debug/MWDebug.php on line 309
[XR9Div3KH7nsaq5OXHatkQAAAAM] /danleffwiki/wiki/ MWException from line 187 of /home/danleff2/public_html/danleffwiki/wiki/includes/MagicWord.php: Error: invalid magic word 'customtitle'
Backtrace:
  1. 0 /home/danleff2/public_html/danleffwiki/wiki/includes/MagicWordFactory.php(222): MagicWord->load(string)
  2. 1 /home/danleff2/public_html/danleffwiki/wiki/includes/parser/Parser.php(4958): MagicWordFactory->get(string)
  3. 2 /home/danleff2/public_html/danleffwiki/wiki/includes/StubObject.php(112): Parser->setFunctionHook(string, array)
  4. 3 /home/danleff2/public_html/danleffwiki/wiki/includes/StubObject.php(138): StubObject->_call(string, array)
  5. 4 /home/danleff2/public_html/danleffwiki/wiki/extensions/customtitle.php(36): StubObject->__call(string, array)
  6. 5 /home/danleff2/public_html/danleffwiki/wiki/includes/Setup.php(903): CustomTitle_MediaWiki->setupExtensionFunction()
  7. 6 /home/danleff2/public_html/danleffwiki/wiki/includes/WebStart.php(77): require_once(string)
  8. 7 /home/danleff2/public_html/danleffwiki/wiki/index.php(39): require(string)
  9. 8 {main} Danleff (talk) 12:35, 5 July 2019 (UTC)
Can you run rebuildLocalisationCache.php? MarkAHershberger(talk) 14:05, 5 July 2019 (UTC)
Excuse my inability to have full knowledge of what you are asking me to do. This wiki is on a commercial server. Where would I run this command from? I am not sure if I have access to do this. Danleff (talk) 17:18, 5 July 2019 (UTC)
Do you have command line access?
Does the LocalSettings.php have any setting for $wgMessageCacheType or $wgMainCacheType?
Could you try adding
$wgMessageCacheType = CACHE_NONE;
to your LocalSettings.php? MarkAHershberger(talk) 19:20, 5 July 2019 (UTC)
I have no command line access. I called my IP provider who confirmed this.
$wgMessageCacheType = CACHE_NONE added
$wgMainCacheType = CACHE_NONE was already in the LocalSettings.php file.
Same result when I visit the wiki.
Notice: "" is not a valid magic word for "customtitle" [Called from Language::getMagic in /home/danleff2/public_html/danleffwiki/wiki/languages/Language.php at line 3220] in /home/danleff2/public_html/danleffwiki/wiki/includes/debug/MWDebug.php on line 309
[XR@ms@JsJitDukhxkfNTcwAAAAU] /danleffwiki/wiki/ MWException from line 187 of /home/danleff2/public_html/danleffwiki/wiki/includes/MagicWord.php: Error: invalid magic word 'customtitle'
Backtrace:
#0 /home/danleff2/public_html/danleffwiki/wiki/includes/MagicWordFactory.php(222): MagicWord->load(string)
#1 /home/danleff2/public_html/danleffwiki/wiki/includes/parser/Parser.php(4958): MagicWordFactory->get(string)
#2 /home/danleff2/public_html/danleffwiki/wiki/includes/StubObject.php(112): Parser->setFunctionHook(string, array)
#3 /home/danleff2/public_html/danleffwiki/wiki/includes/StubObject.php(138): StubObject->_call(string, array)
#4 /home/danleff2/public_html/danleffwiki/wiki/extensions/customtitle.php(36): StubObject->__call(string, array)
#5 /home/danleff2/public_html/danleffwiki/wiki/includes/Setup.php(903): CustomTitle_MediaWiki->setupExtensionFunction()
#6 /home/danleff2/public_html/danleffwiki/wiki/includes/WebStart.php(77): require_once(string)
#7 /home/danleff2/public_html/danleffwiki/wiki/index.php(39): require(string)
#8 {main} Danleff (talk) 19:43, 5 July 2019 (UTC)
I just noticed that you are using an old, outdated extension, CustomTitle. As the extension page says:
This parser function is now provided by MediaWiki core. Use {{DISPLAYTITLE}} and enable $wgAllowDisplayTitle to allow arbitrary titles.
I'm sure that if you remove the
require_once( "$IP/extensions/customtitle.php" );
from your LocalSettings.php, it will resolve this problem. MarkAHershberger(talk) 01:32, 6 July 2019 (UTC)
This did resolve the issue! Many Thanks to you and your team! Danleff (talk) 10:03, 6 July 2019 (UTC)
I have a similar problem after the update I only get the page displayed. does anyone know a solution?
[8c334f7ff0e212ae36fc7dfb] /wiki/index.php?title=Hauptseite MWException from line 182 of /var/www/html/mediawiki-1.32.0/includes/MagicWord.php: Error: invalid magic word 'haclaccess'
Backtrace:
#0 /var/www/html/mediawiki-1.32.0/includes/MagicWordFactory.php(222): MagicWord->load(string)
#1 /var/www/html/mediawiki-1.32.0/includes/parser/Parser.php(5288): MagicWordFactory->get(string)
#2 /var/www/html/mediawiki-1.32.0/includes/StubObject.php(112): Parser->setFunctionHook(string, string)
#3 /var/www/html/mediawiki-1.32.0/includes/StubObject.php(138): StubObject->_call(string, array)
#4 /var/www/html/mediawiki-1.32.0/extensions/IntraACL/includes/GlobalFunctions.php(323): StubObject->__call(string, array)
#5 /var/www/html/mediawiki-1.32.0/includes/Setup.php(906): haclfSetupExtension()
#6 /var/www/html/mediawiki-1.32.0/includes/WebStart.php(81): require_once(string)
#7 /var/www/html/mediawiki-1.32.0/index.php(41): require(string)
#8 {main} 2003:E2:B707:4200:49A8:C58B:F30C:7109 (talk) 00:26, 18 March 2020 (UTC)
Is your site available somewhere that we can look at it? Did you try running rebuildLocalisationCache? MarkAHershberger(talk) 17:47, 18 March 2020 (UTC)

Error upgrading 1.33

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


I use mediawiki in my website https://www.wikidonca.it/

1 - Never had a problem before. This time from 1.32.2 to 1.33 instead I encounter several errors. First of all the function getallheaders ( vendor/ralouphie/getallheaders ) that is called in vendor/composer/autoload files.php and vendor/composer/autoload_files.php is in the code but the files are not included in the downloadable package of the new version (!?). I solved disabling the row.

2 - After that, a lot of error converting database.

3 - At the end.... when process ends successfully (with a lot of work).. this!


[XR42tAKkHihz8Xc0Ilb3mAAAAAA] /dizionario/Pagina_principale MediaWiki\Revision\RevisionAccessException from line 131 of /home/wikidonca/public_html/includes/Revision/RevisionStoreCacheRecord.php: Unable to load fresh row for rev_id: 14801

Backtrace:

#0 /home/wikidonca/public_html/includes/Revision/RevisionStoreCacheRecord.php(79): MediaWiki\Revision\RevisionStoreCacheRecord->loadFreshRow()

#1 /home/wikidonca/public_html/includes/Revision.php(898): MediaWiki\Revision\RevisionStoreCacheRecord->getVisibility()

#2 /home/wikidonca/public_html/includes/Revision.php(1227): Revision->getVisibility()

#3 /home/wikidonca/public_html/includes/page/Article.php(456): Revision->userCan(integer, User)

#4 /home/wikidonca/public_html/includes/page/Article.php(713): Article->fetchRevisionRecord()

#5 /home/wikidonca/public_html/includes/actions/ViewAction.php(68): Article->view()

#6 /home/wikidonca/public_html/includes/MediaWiki.php(499): ViewAction->show()

#7 /home/wikidonca/public_html/includes/MediaWiki.php(294): MediaWiki->performAction(Article, Title)

#8 /home/wikidonca/public_html/includes/MediaWiki.php(865): MediaWiki->performRequest()

#9 /home/wikidonca/public_html/includes/MediaWiki.php(515): MediaWiki->main()

#10 /home/wikidonca/public_html/index.php(42): MediaWiki->run()

#11 {main}



Cesarinik (talk) 18:25, 4 July 2019 (UTC)

Seems that this error are only in the Main Page... other pages works.. Cesarinik (talk) 18:33, 4 July 2019 (UTC)
First, I tried reproducing your problem, but couldn't get your exact error on the downloaded tarball.
I saw that your page had the error and then tried adding "?action=purge". That seemed to clear up the error. MarkAHershberger(talk) 19:01, 4 July 2019 (UTC)
Hitting Special:Random a few times seems to not cause the error, though. So is it fixed? MarkAHershberger(talk) 19:03, 4 July 2019 (UTC)
Also, I'm seeing
IncompleteRevisionException from line 333 of .../includes/Revision/SlotRecord.php: Uninitialized field: content_address
on your site now, so I'm wondering if you ran update.php? MarkAHershberger(talk) 19:06, 4 July 2019 (UTC)
Yeah... I run update.php as usual for every version upgrade Cesarinik (talk) 22:22, 4 July 2019 (UTC)
Now it works... THANK YOU! Cesarinik (talk) 22:24, 4 July 2019 (UTC)
Your user page isn't working: https://www.wikidonca.it/dizionario/Utente:Cesarinik MarkAHershberger(talk) 00:40, 5 July 2019 (UTC)
It works too... after ?action=purge.
Error was in the cached page. Cesarinik (talk) 07:05, 5 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Nesecito ayuda con los enlaces permanentes mail @gmail.com

hola, mi wiki es sourcewiki.org, estoy en un hosting compartido con apache, apenas 1 mes llevo configurándola y me gustaría que alguien me ayude no se si tendría que pagarle para cambiar de sourcewiki.org/index.php/main_page a sourcewiki/wiki/main_page la verdad llevo mas de 15 días investigando y probando y la verdad soy muy malo configurando, Estoy desesperado y necesito ayuda. 148.0.155.168 (talk) 18:48, 4 July 2019 (UTC)

See Manual:Short URL/Apache, which parts are you having a problem with? AhmadF.Cheema (talk) 00:20, 5 July 2019 (UTC)

ussues /index.php/ to /wiki/ Help

hello everyone I speak to you because I would like someone to give me the instructions for a shared hosting that also has apache is that I want to remove the indexphp and modify it with wiki in the same way as wikipedia and mediawiki Samueloweb (talk) 19:39, 4 July 2019 (UTC)

First, move your wiki from the root of your webserver to a folder called just "w".
Next add an .htaccess file in your root folder with the following:
## https://www.mediawiki.org/wiki/Manual:Short_URL/Apache
# Enable the rewrite engine
RewriteEngine On
# Short URL for wiki pages
RewriteRule ^/?wiki(/.*)?$ %{DOCUMENT_ROOT}/w/index.php [L]
# Redirect / to Main Page
RewriteRule ^/*$ %{DOCUMENT_ROOT}/w/index.php [L]
If you've tried this already, try again.
What happens when you follow the above two steps? MarkAHershberger(talk) 20:39, 4 July 2019 (UTC)
Hello bro, sorry I'm very bad really, I don't speak English I don't understand the part where you say move the root to a folder called w, I have to move all the files or just create a file called .htaccess Samueloweb (talk) 21:04, 4 July 2019 (UTC)
  1. Create a folder named "w" in the same directory that has MediaWiki right now.
  2. Move everything in to "w".
  3. Create a file at the same level as "w" named ".htaccess" with the above contents.
So if everything right now is in "public_html", you would create "public_html/w" and move all the files and folders (index.php, includes, load.php, etc.) into the folder.
Then you would create a file "public_html/.htaccess" with the contents above.
Now, when you look at all the files and folders in public_html, you should only see "w" and ".htaccess". MarkAHershberger(talk) 21:15, 4 July 2019 (UTC)
thankssss bro you are Awesomeeeeeeeee now mi page are fixed Samueloweb (talk) 22:23, 4 July 2019 (UTC)

Login Error with LDAP Authentication Extension

I upgraded from Version 1.32.2 to 1.33.0. Since then I cannot log in to the wiki with the LDAP Authentication. We would still like to use that extension so that our people don't need to remember a new password, and we do it for security reasons. What happened with the LDAP Authentication extension that it totally shot the login procedure? And what alternative is there to that extension? Ablum010777 (talk) 06:46, 5 July 2019 (UTC)
Did you manage to fix the error. what is the solution? Sam Madisha (talk) 09:50, 9 October 2019 (UTC)
You can try LDAP Stack. See also LDAP hub. Osnard (talk) 09:06, 5 July 2019 (UTC)
I read everything that was written there, but it seems very complicated to me, and therefore useless. What I need is a simple extension that authenticates users against our LDAP through contact with the LDAP server. The LDAP Authentication extension provided us with exactly that. I did not see any way to configure Auth_remoteuser or LDAP Authorization in that same way. How about simply retrofitting the LDAP Authentication extension for MediaWiki 1.33.0? Ablum010777 (talk) 06:26, 8 July 2019 (UTC)
Same problem here :`-( 185.20.218.15 (talk) 12:29, 8 July 2019 (UTC)
Here the same. Would be nice, when it can be fixed. 217.114.64.90 (talk) 10:17, 1 August 2019 (UTC)
Please take a look at these error messages from my Apache Webserver error log:
[Fri Aug 09 10:10:34.102519 2019] [php7:warn] [pid 21580] [client 10.50.152.24:60371] PHP Warning:  array_merge(): Argument #1 is not an array in /srv/www/htdocs/testwiki/extensions/PluggableAuth/includes/PluggableAuthBeginAuthenticationRequest.php on line 36
[Fri Aug 09 10:10:34.102659 2019] [php7:warn] [pid 21580] [client 10.50.152.24:60371] PHP Warning:  array_filter() expects parameter 1 to be array, null given in /srv/www/htdocs/testwiki/includes/auth/AuthenticationRequest.php on line 308
[Fri Aug 09 10:10:34.102754 2019] [php7:warn] [pid 21580] [client 10.50.152.24:60371] PHP Warning:  array_keys() expects parameter 1 to be array, null given in /srv/www/htdocs/testwiki/includes/auth/AuthenticationRequest.php on line 308
[Fri Aug 09 10:10:34.102829 2019] [php7:warn] [pid 21580] [client 10.50.152.24:60371] PHP Warning:  array_intersect(): Argument #2 is not an array in /srv/www/htdocs/testwiki/includes/auth/AuthenticationRequest.php on line 312
[Fri Aug 09 10:10:34.102924 2019] [php7:warn] [pid 21580] [client 10.50.152.24:60371] PHP Warning:  in_array() expects parameter 2 to be array, null given in /srv/www/htdocs/testwiki/includes/auth/AuthenticationRequest.php on line 329
[Fri Aug 09 10:10:34.103009 2019] [php7:warn] [pid 21580] [client 10.50.152.24:60371] PHP Warning:  in_array() expects parameter 2 to be array, null given in /srv/www/htdocs/testwiki/includes/auth/AuthenticationRequest.php on line 329
[Fri Aug 09 10:10:34.103107 2019] [php7:warn] [pid 21580] [client 10.50.152.24:60371] PHP Warning:  array_merge(): Argument #1 is not an array in /srv/www/htdocs/testwiki/extensions/PluggableAuth/includes/PluggableAuthBeginAuthenticationRequest.php on line 36
[Fri Aug 09 10:10:34.103228 2019] [php7:warn] [pid 21580] [client 10.50.152.24:60371] PHP Warning:  array_merge(): Argument #1 is not an array in /srv/www/htdocs/testwiki/extensions/PluggableAuth/includes/PluggableAuthBeginAuthenticationRequest.php on line 36
[Fri Aug 09 10:10:34.103319 2019] [php7:warn] [pid 21580] [client 10.50.152.24:60371] PHP Warning:  array_filter() expects parameter 1 to be array, null given in /srv/www/htdocs/testwiki/includes/auth/AuthenticationRequest.php on line 308
[Fri Aug 09 10:10:34.103392 2019] [php7:warn] [pid 21580] [client 10.50.152.24:60371] PHP Warning:  array_keys() expects parameter 1 to be array, null given in /srv/www/htdocs/testwiki/includes/auth/AuthenticationRequest.php on line 308
[Fri Aug 09 10:10:34.103482 2019] [php7:warn] [pid 21580] [client 10.50.152.24:60371] PHP Warning:  array_intersect(): Argument #2 is not an array in /srv/www/htdocs/testwiki/includes/auth/AuthenticationRequest.php on line 312
[Fri Aug 09 10:10:34.103573 2019] [php7:warn] [pid 21580] [client 10.50.152.24:60371] PHP Warning:  in_array() expects parameter 2 to be array, null given in /srv/www/htdocs/testwiki/includes/auth/AuthenticationRequest.php on line 329
[Fri Aug 09 10:10:34.103663 2019] [php7:warn] [pid 21580] [client 10.50.152.24:60371] PHP Warning:  in_array() expects parameter 2 to be array, null given in /srv/www/htdocs/testwiki/includes/auth/AuthenticationRequest.php on line 329
[Fri Aug 09 10:10:34.103753 2019] [php7:warn] [pid 21580] [client 10.50.152.24:60371] PHP Warning:  array_merge(): Argument #1 is not an array in /srv/www/htdocs/testwiki/extensions/PluggableAuth/includes/PluggableAuthBeginAuthenticationRequest.php on line 36 Ablum010777 (talk) 08:14, 9 August 2019 (UTC)
It looks like $wgPluggableAuth_ExtraLoginFields is not set properly by LDAPAuthentication2. But this UnitTest passes on REL1_33: https://github.com/wikimedia/mediawiki-extensions-LDAPAuthentication2/blob/f8607b952959c477c62d2b8207cf835f049d145b/tests/phpunit/SetupTest.php
@Cindy.cicalese, do you have an idea?
@Ablum010777, what PHP version are you using? Osnard (talk) 14:35, 12 August 2019 (UTC)
What version of MediaWiki and relevant extensions are you using? In particular, I find it odd that you are getting an exception at "PluggableAuthBeginAuthenticationRequest.php on line 36", since there are not 36 lines in that file, nor have there been in the history of that file as far as I can tell. I'm guessing that you added some debugging statements to that file that changed the line count? If so, I'd be interested in knowing what the values are of $GLOBALS['wgPluggableAuth_ExtraLoginFields'] and parent::getFieldInfo() before the call to array_merge(). Cindy.cicalese (talk) 14:53, 12 August 2019 (UTC)
I am working with PHP Version 7.2.5. (Osnard wrote that this would be fine.)
These are the extensions in my LocalSettings.php:
wfLoadExtension( 'CodeEditor' );
wfLoadExtension( 'PdfHandler' );
wfLoadExtension( 'SyntaxHighlight_GeSHi' );
wfLoadExtension( 'WikiEditor' );
wfLoadExtension( 'SimpleMathJax' );
require_once( "$IP/extensions/Realnames/Realnames.php" );
This is the configuration for the LDAP Authentication:
wfLoadExtension( 'PluggableAuth' );
wfLoadExtension ( 'Auth_remoteuser' );
wfLoadExtension ( 'LDAPProvider' );
wfLoadExtension ( 'LDAPAuthentication2' );
wfLoadExtension ( 'LDAPAuthorization' );
wfLoadExtension ( 'LDAPUserInfo' );
$wgPluggableAuth_EnableLocalLogin = true;
$LDAPAuthorizationAutoAuthRemoteUserStringParser = 'username-at-domain';
$LDAPAuthentication2UsernameNormalizer = 'strtolower';
$LDAPAuthentication2AllowLocalLogin = true;
$wgAuthRemoteuserAllowUserSwitch = true;
$wgPluggableAuth_ExtraLoginFields = array (
   'Login' => array ( 'type' => 'string', 'label' => 'Benutzername', 'optional' => false, 'sensitive' => true ),
   'Passwort' => array( 'type' => 'password', 'label' => 'Passwort', 'optional' => false, 'sensitive' => true )
);
$wgAuthRemoteuserUserName = function () {
   $user = <nowiki>''</nowiki>;
   if ( isset ($_SERVER[ 'REMOTE_USER' ] ) ) {
        $user = strtolower ( $_SERVER[ 'REMOTE_USER' ] );
   }
   return $user;
};
$LDAPProviderDomainConfigs = "/etc/mediawiki/ldapprovider.json";
I also have the following extensions activated:
SphinxSearch
Collection (for PDF rendering)
Visual Editor
This is the ldapprovider.json file:
{
   'testwiki': {
       'connection': {
           "server": "geo-infra.rlp",
           "options": {
               "LDAP_OPT_DEREF": 1
           },
           "basedn": "ou=group,ou=VermKV,o=Landesverwaltung Rheinland-Pfalz,c=de",
           "userbasedn": "ou=group,ou=VermKV,o=Landesverwaltung Rheinland-Pfalz,c=de",
           "groupbasedn": "ou=group,ou=VermKV,o=Landesverwaltung Rheinland-Pfalz,c=de",
           "searchattribute": "uid",
           "usernameattribute": "uid",
           "realnameattribute": "displayName",
           "emailattribute": "mail",
           "grouprequest": "MediaWiki\\Extension\\LDAPProvider\\UserGroupRequest\\GroupMember::factory"
       },
       'authorization': {
           'rules': {
               'groups': {
                   'required': "cn=wiki_testcontainer,ou=group,ou=VermKV,o=Landesverwaltung Rheinland-Pfalz,c=de"
               }
           }
       },
       'userinfo': {
           'attributes-map': {
               'email': 'mail',
               'realname': 'displayName'
           }
       }
   }
}
And the PluggableAuthBeginAuthenticationRequest.php:
<?php
use \MediaWiki\Auth\ButtonAuthenticationRequest;
use \MediaWiki\Auth\AuthManager;
class PluggableAuthBeginAuthenticationRequest extends
       ButtonAuthenticationRequest {
       public function __construct() {
               if ( isset( $GLOBALS['wgPluggableAuth_ButtonLabelMessage'] ) ) {
                       $label = wfMessage( $GLOBALS['wgPluggableAuth_ButtonLabelMessage'] );
               } elseif ( $GLOBALS['wgPluggableAuth_ButtonLabel'] ) {
                       $label = new RawMessage( $GLOBALS['wgPluggableAuth_ButtonLabel'] );
               } else {
                       $label = wfMessage( 'pluggableauth-loginbutton-label' );
               }
               parent::__construct(
                       'pluggableauthlogin',
                       $label,
                       wfMessage( 'pluggableauth-loginbutton-help' ),
                       true );
       }
       /**
        * Returns field information.
        * @return array field information
        */
       public function getFieldInfo() {
               if ( $this->action !== AuthManager::ACTION_LOGIN ) {
                       return [];
               }
               error_log( 'A:' . var_export( $GLOBALS['wgPluggableAuth_ExtraLoginFields'], 1 ) ); // this is what Osnard asked me to add
               error_log( 'B:' . var_export( parent::getFieldInfo(), 1 ) ); // this, too
               error_log( 'C:' . var_export( array_merge( $GLOBALS['wgPluggableAuth_ExtraLoginFields'], parent::getFieldInfo() ), 1 ) ); // this, too.
               return array_merge( $GLOBALS['wgPluggableAuth_ExtraLoginFields'],
                       parent::getFieldInfo() );
       }
}
The result of Osnard's recommendations are:
A:MediaWiki\\Extension\\LDAPAuthentication2\\ExtraLoginFields::__set_state( 
   array(
       'domain' => array (
           'type' => 'select',
           'label' => Message::__set_state( 
               array(
                   'interface' => true,
                   'language' => false,
                   'key' => 'yourdomainname',
                   'keysToTry' => array (
                       0 => 'yourdomainname',
                       ),
                       'parameters' => 
                       array (
                       ),
                       'format' => 'parse',
                       'useDatabase' => true,
                       'title' => NULL,
                       'content' => NULL,
                       'message' => NULL,
                   )
               ),
               'help' => Message::__set_state( 
                   array(
                       'interface' => true,
                       'language' => false,
                       'key' => 'authmanager-domain-help',
                       'keysToTry' => array (
                           0 => 'authmanager-domain-help',
                       ),
                       'parameters' => array (
                       ),
                       'format' => 'parse',
                       'useDatabase' => true,
                       'title' => NULL,
                       'content' => NULL,
                       'message' => NULL,
                   )
               ),
               'options' => array (
                   'testwiki' => RawMessage::__set_state(
                       array(
                           'interface' => true,
                           'language' => false,
                           'key' => 'testwiki',
                           'keysToTry' => array (
                               0 => 'testwiki',
                           ),
                           'parameters' => array (
                           ),
                           'format' => 'parse',
                           'useDatabase' => true,
                           'title' => NULL,
                           'content' => NULL,
                           'message' => 'testwiki',
                       )
                   )
               ),
               'local' => RawMessage::__set_state(
                   array(    
                       'interface' => true,
                       'language' => false,
                       'key' => 'local',
                       'keysToTry' => array (
                           0 => 'local',
                       ),
                       'parameters' => array (
                       ),
                       'format' => 'parse',
                       'useDatabase' => true,
                       'title' => NULL,
                       'content' => NULL,
                       'message' => 'local',
                   )
               ),
           ),
       ),
       'username' => array (
           'type' => 'string',
           'label' => Message::__set_state(
               array(
                   'interface' => true,
                   'language' => false,
                   'key' => 'userlogin-yourname',
                   'keysToTry' => array (
                       0 => 'userlogin-yourname',
                   ),
                   'parameters' => array (
                   ),
                   'format' => 'parse',
                   'useDatabase' => true,
                   'title' => NULL,
                   'content' => NULL,
                   'message' => NULL,
               )
           ),
           'help' => Message::__set_state(
               array(
                   'interface' => true,
                   'language' => false,
                   'key' => 'authmanager-username-help',
                   'keysToTry' => array (
                       0 => 'authmanager-username-help',
                   ),
                   'parameters' => array (
                   ),
                   'format' => 'parse',
                   'useDatabase' => true,
                   'title' => NULL,
                   'content' => NULL,
                   'message' => NULL,
               )
           ),
       ),
       'password' => array (
           'type' => 'password',
           'label' => Message::__set_state( 
               array(
                   'interface' => true,
                   'language' => false,
                   'key' => 'userlogin-yourpassword',
                   'keysToTry' => array (
                       0 => 'userlogin-yourpassword',
                   ),
                   'parameters' => array (
                   ),
                   'format' => 'parse',
                   'useDatabase' => true,
                   'title' => NULL,
                   'content' => NULL,
                   'message' => NULL,
               )
           ),
           'help' => Message::__set_state(
               array(
                   'interface' => true,
                   'language' => false,
                   'key' => 'authmanager-password-help',
                   'keysToTry' => array (
                       0 => 'authmanager-password-help',
                   ),
                   'parameters' => array (
                   ),
                   'format' => 'parse',
                   'useDatabase' => true,
                   'title' => NULL,
                   'content' => NULL,
                   'message' => NULL,
               )
           ),
           'sensitive' => true,
       ),
   )
),
B:array (
   'pluggableauthlogin' => array (
       'type' => 'button',
       'label' => Message::__set_state(
           array(
               'interface' => true,
               'language' => false,
               'key' => 'pluggableauth-loginbutton-label',
               'keysToTry' => array (
                   0 => 'pluggableauth-loginbutton-label',
               ),
               'parameters' => array (
               ),
               'format' => 'parse',
               'useDatabase' => true,
               'title' => NULL,
               'content' => NULL,
               'message' => NULL,
           )
       ),
       'help' => Message::__set_state(
           array(
               'interface' => true,
               'language' => false,
               'key' => 'pluggableauth-loginbutton-help',
               'keysToTry' => array (
                   0 => 'pluggableauth-loginbutton-help',
               ),
               'parameters' => array (
               ),
               'format' => 'parse',
               'useDatabase' => true,
               'title' => NULL,
               'content' => NULL,
               'message' => NULL,
           )
       ),
   ),
),
C: NULL [[User:Ablum010777|Ablum010777]] ([[User talk:Ablum010777|talk]]) 05:20, 13 August 2019 (UTC)
:Can you try to remove the <code>$wgPluggableAuth_ExtraLoginFields</code> from you configuration? This is set implicitly by [[Extension:LDAPAuthentication2]]. Maybe this collides. [[User:Osnard|Osnard]] ([[User talk:Osnard|talk]]) 06:15, 13 August 2019 (UTC)
:I already did, but it doesn't help. This is always the result:
:[89dad82860e957e43a00ac89] /testwiki/   MWException from line 54 of /srv/www/htdocs/testwiki/extensions/LDAPProvider/src/DomainConfigProvider/LocalJSONFile.php: Could not parse configuration file '/etc/mediawiki/ldapprovider.json'!
:Backtrace:
:<nowiki>#</nowiki>0 /srv/www/htdocs/testwiki/extensions/LDAPProvider/src/DomainConfigProvider/LocalJSONFile.php(73): MediaWiki\Extension\LDAPProvider\DomainConfigProvider\LocalJSONFile->__construct(string)
:<nowiki>#</nowiki>1 [internal function]: MediaWiki\Extension\LDAPProvider\DomainConfigProvider\LocalJSONFile::newInstance(MediaWiki\Extension\LDAPProvider\Config)
:<nowiki>#</nowiki>2 /srv/www/htdocs/testwiki/extensions/LDAPProvider/src/DomainConfigFactory.php(106): call_user_func_array(string, array)
:<nowiki>#</nowiki>3 /srv/www/htdocs/testwiki/extensions/LDAPAuthentication2/src/Setup.php(13): MediaWiki\Extension\LDAPProvider\DomainConfigFactory::getInstance()
:<nowiki>#</nowiki>4 /srv/www/htdocs/testwiki/includes/Setup.php(903): MediaWiki\Extension\LDAPAuthentication2\Setup::init()
:<nowiki>#</nowiki>5 /srv/www/htdocs/testwiki/includes/WebStart.php(77): require_once(string)
:<nowiki>#</nowiki>6 /srv/www/htdocs/testwiki/index.php(39): require(string)
:<nowiki>#</nowiki>7 {main} [[User:Ablum010777|Ablum010777]] ([[User talk:Ablum010777|talk]]) 06:28, 13 August 2019 (UTC)
:The error message <code>Could not parse configuration file '/etc/mediawiki/ldapprovider.json'!</code> suggests that there might be a syntax error in that file or the file is nor readable by the webserver. From the example you have posted above I believe the single quotes are the problem. Try using double quotes everywhere in JSON. [[User:Osnard|Osnard]] ([[User talk:Osnard|talk]]) 12:17, 13 August 2019 (UTC)
:I use double quotes in the JSON file everywhere. Besides I am testing on a console now. It seems to me that the variable containing the text boxes for the login name and the password are not passed to the LocalJSONFile.php file correctly, since I always read NULL. This is my ldapprovider.json now:
:<code>{</code>
:<code>   "testwiki": {</code>
:<code>       "connection": {</code>
:<code>           "server": "geo-infra.rlp",</code>
:<code>           "options": {</code>
:<code>               "LDAP_OPT_DEREF": 1</code>
:<code>           },</code>
:<code>           "basedn": "ou=group,ou=VermKV,o=Landesverwaltung Rheinland-Pfalz,c=de",</code>
:<code>           "userbasedn": "ou=group,ou=VermKV,o=Landesverwaltung Rheinland-Pfalz,c=de",</code>
:<code>           "groupbasedn": "ou=group,ou=VermKV,o=Landesverwaltung Rheinland-Pfalz,c=de",</code>
:<code>           "searchattribute": "uid",</code>
:<code>           "usernameattribute": "uid",</code>
:<code>           "realnameattribute": "displayName",</code>
:<code>           "emailattribute": "mail",</code>
:<code>           "grouprequest": "MediaWiki\\Extension\\LDAPProvider\\UserGroupRequest\\GroupMember::factory"</code>
:<code>       },</code>
:<code>       "authorization": {</code>
:<code>           "rules": {</code>
:<code>               "groups": {</code>
:<code>                   "required": "cn=wiki_testcontainer,ou=group,ou=VermKV,o=Landesverwaltung Rheinland-Pfalz,c=de"</code>
:<code>               }</code>
:<code>           }</code>
:<code>       },</code>
:<code>       "authentication": {</code>
:<code>           "emailattribute": 'mail',</code>
:<code>           "realnameattribute": "displayName"</code>
:<code>           "usernameattribute": "uid"</code>
:<code>       }</code>
:<code>   }</code>
:<code>}</code>
:That is also why these two fields (login name and password) are missing when I set the local login variables to false. [[User:Ablum010777|Ablum010777]] ([[User talk:Ablum010777|talk]]) 12:52, 13 August 2019 (UTC)
:From the code you posted, your "C:" printout should be an array containing the merged contents of the two other arrays, but instead it is printing:
:C: NULL
:which would match the fact that the function appears to be returning NULL. But, how can the result of merging two populated arrays be null? [[User:Cindy.cicalese|Cindy.cicalese]] ([[User talk:Cindy.cicalese|talk]]) 20:17, 13 August 2019 (UTC)
:The problem has been solved. The variable $GLOBALS['PluggableAuth_ExtraLoginFields'] needs explicit typecasting to array. [[User:Ablum010777|Ablum010777]] ([[User talk:Ablum010777|talk]]) 05:22, 14 August 2019 (UTC)
:Can you please tell '''where''' this typecast was required? Because as far as I can tell it ''is already casted'' in [[Extension:LDAPAuthentication2]]: https://github.com/wikimedia/mediawiki-extensions-LDAPAuthentication2/blob/e170a82153fa8d489a1e1c3b8f5ff1e95539a230/src/Setup.php#L14-L15 [[User:Osnard|Osnard]] ([[User talk:Osnard|talk]]) 09:03, 14 August 2019 (UTC)
:In PluggableAuthBeginAuthenticationRequest.php (code line printed in bold):
:<?php
:use \MediaWiki\Auth\ButtonAuthenticationRequest;
:use \MediaWiki\Auth\AuthManager;
:class PluggableAuthBeginAuthenticationRequest extends
:       ButtonAuthenticationRequest {
:       public function __construct() {
:               if ( isset( $GLOBALS['wgPluggableAuth_ButtonLabelMessage'] ) ) {
:                       $label = wfMessage( $GLOBALS['wgPluggableAuth_ButtonLabelMessage'] );
:               } elseif ( $GLOBALS['wgPluggableAuth_ButtonLabel'] ) {
:                       $label = new RawMessage( $GLOBALS['wgPluggableAuth_ButtonLabel'] );
:               } else {
:                       $label = wfMessage( 'pluggableauth-loginbutton-label' );
:               }
:               parent::__construct(
:                       'pluggableauthlogin',
:                       $label,
:                       wfMessage( 'pluggableauth-loginbutton-help' ),
:                       true );
:       }
:       /**
:        * Returns field information.
:        * @return array field information
:        */
:       public function getFieldInfo() {
:               if ( $this->action !== AuthManager::ACTION_LOGIN ) {
:                       return [];
:               }
:               '''return array_merge( (array) $GLOBALS['wgPluggableAuth_ExtraLoginFields'],'''
:'''                       parent::getFieldInfo() );'''
:       }
:} [[User:Ablum010777|Ablum010777]] ([[User talk:Ablum010777|talk]]) 09:12, 14 August 2019 (UTC)
:Ah, interesting. The printout:
:error_log( 'A:' . var_export( $GLOBALS['wgPluggableAuth_ExtraLoginFields'], 1 ) );
:is giving:
:A:MediaWiki\\Extension\\LDAPAuthentication2\\ExtraLoginFields::__set_state( 
:   array(
:...
:rather than
:A:array(
:... [[User:Cindy.cicalese|Cindy.cicalese]] ([[User talk:Cindy.cicalese|talk]]) 14:25, 14 August 2019 (UTC)
:Well, `ExtraLoginFields` is an `ArrayObject`. But I do an explicit cast to `array` before assignment (https://github.com/wikimedia/mediawiki-extensions-LDAPAuthentication2/blob/e170a82153fa8d489a1e1c3b8f5ff1e95539a230/src/Setup.php#L14-L15). And even my UnitTest passes: https://github.com/wikimedia/mediawiki-extensions-LDAPAuthentication2/blob/e170a82153fa8d489a1e1c3b8f5ff1e95539a230/tests/phpunit/SetupTest.php [[User:Osnard|Osnard]] ([[User talk:Osnard|talk]]) 17:03, 17 August 2019 (UTC)
:This feels like overkill. We use LDAP with Auth_remoteuser but don't need any MediaWiki extensions for the LDAP part, since Apache httpd does the authentication to the LDAP server. The relevant bit of our LocalSettings.php file looks like this:
:<code>wfLoadExtension('Auth_remoteuser');</code>
:<code>#$wgAuth = new Auth_remoteuser();</code>
:<code>$wgAuthRemoteuserMailDomain = "spawar.navy.mil";</code>
:Then we put a .htaccess file in the root of our wiki with the following (we could also do it in a config file in /etc/httpd/conf.d/):
:<code>AuthName "wiki"</code>
:<code>AuthType Basic</code>
:<code>AuthBasicProvider ldap</code>
:<code>AuthLDAPURL <our LDAP url></code>
:<code>Require valid-user</code> [[User:Hawaiian717|Hawaiian717]] ([[User talk:Hawaiian717|talk]]) 15:33, 10 October 2019 (UTC)
:Yes. This is true, if you don't need features like form-based-authentication, group-based-login-restrictions, groupy-sync or user-info-synchronization. [[User:Osnard|Osnard]] ([[User talk:Osnard|talk]]) 11:58, 14 October 2019 (UTC)

== Alternative Look to my Mediawiki (to look like my old Sphinx Doc) ==

Hello Community,

Is there a Skin or some workaround to make my Mediawiki look like my old Sphinx Doc ? People got used to the look and i am asked to reconstruct it (but now we are using Mediawiki)


Thanks in advance [[Special:Contributions/141.90.2.44|141.90.2.44]] ([[User talk:141.90.2.44|talk]]) 06:51, 5 July 2019 (UTC)
:I don't know how the sphinx site looks, but you could look at the [[:Category:Skin extensions|skins category]].  Skins like [[Skin:Tweeki|Tweeki]] should be very customizable. <span style="color:#d30000">☠</span>[[User:MarkAHershberger|MarkAHershberger]]<span style="color:#d30000">☢</span>([[User_talk:MarkAHershberger|talk]])<span style="color:#d30000">☣</span> 14:38, 5 July 2019 (UTC)
:In my Case Sphinx looks like a Folder/Tree Structure. Meaning:
:On the left windows pane i have 5 main titles. By clicking on one of those titles a folder structure like a tree opens up and i see "sub-folders". This expands and colapses depending on what i click on. the Right window pane shows the Information depending on what i have clicked.
:I could not find a way in tweeki to realise this.... [[Special:Contributions/141.90.2.44|141.90.2.44]] ([[User talk:141.90.2.44|talk]]) 12:51, 9 July 2019 (UTC)

== Links & page not working -> 404 error ==
{{Archive top|result=The config file was too old, writing a brand new fixed all issues.|status=resolved}}

Hi migrated MW to the latest version, kept old config file, images folder. Ran the upgrade script with no issue but now only the "/" page is working any other pages gives 404 (ie: <nowiki>https://tld/Special:UserLogin</nowiki> ) Any idea ?. os : SL7.5 httpd-2.4.6-80.sl7_5.1.x86_64, php 7.2... [[Special:Contributions/193.190.247.74|193.190.247.74]] ([[User talk:193.190.247.74|talk]]) 10:41, 5 July 2019 (UTC)
:The config file was too old, writing a brand new fixed all issues. [[Special:Contributions/193.190.247.74|193.190.247.74]] ([[User talk:193.190.247.74|talk]]) 13:04, 5 July 2019 (UTC)
{{Archive bottom}}

== Editing global CSS and JS via text editor ==

I use MediaWiki 1.32.0. 

How can one edit global CSS (as of Common.css) and JS (as of Common.js) via a text editor? 

If it cannot be done, is there an option to add similar two files somehow? It's very hard for me to edit only from inside MediaWiki; especially when my site is RTL and not LTR, hence I need to add CSS and JS from a text editor comfortably. [[Special:Contributions/49.230.58.174|49.230.58.174]] ([[User talk:49.230.58.174|talk]]) 10:48, 5 July 2019 (UTC)
:You could edit the CSS in your text editor and then paste it in.
:The [[Extension:CodeEditor|CodeEditor]] extension may be helpful as well. <span style="color:#d30000">☠</span>[[User:MarkAHershberger|MarkAHershberger]]<span style="color:#d30000">☢</span>([[User_talk:MarkAHershberger|talk]])<span style="color:#d30000">☣</span> 14:27, 5 July 2019 (UTC)
:{{FlowMention|MarkAHershberger}} yes, but I'd prefer edit directly and not use any extension... making these files protected from being deleted in upgrades and easily accessible from root directory would have been way easier, in my humble opinion. [[Special:Contributions/182.232.47.153|182.232.47.153]] ([[User talk:182.232.47.153|talk]]) 10:51, 6 July 2019 (UTC)
:If you have access to the server files, there's no need for you to use common.css/js, instead you can make your own simple extension (only need two simple files to register it) which loads your own js/css files through ResourceLoader, and thus you can edit them however you like. [[Special:Contributions/121.219.99.41|121.219.99.41]] ([[User talk:121.219.99.41|talk]]) 13:04, 6 July 2019 (UTC)

== Remove "page matching text" in search results for  "Page title matches" section ==

Hi, 

I would like to modify the search result page in ordet to show only page titles in the "Page title matches section". 

I do not want that section to show the matching "text" from these pages as it actually generates a lot of useless duplicates with the "Page text matches" section. 

I have no idea where to start! 

I am on wikimedia 1.32.0 and i have installed [[Extension:CirrusSearch|CirrusSearch]] but i cannot find options that could help me.

Any help welcomed ^^ [[User:SDFM13|SDFM13]] ([[User talk:SDFM13|talk]]) 12:41, 5 July 2019 (UTC)
:If you want only title matches for your searches, try "intitle:search" where "search" is what you're looking for. <span style="color:#d30000">☠</span>[[User:MarkAHershberger|MarkAHershberger]]<span style="color:#d30000">☢</span>([[User_talk:MarkAHershberger|talk]])<span style="color:#d30000">☣</span> 14:25, 5 July 2019 (UTC)
:Not exactly.
:The search results are listed in 2 main sections 
:1 - Page title matches
:2 - Page text matches
:I want keep both.
:But a search result (in both sections) is displayed like this : 
:[Page title]
:[Text from the page matching the search]
:[Search results data (ex: 457 bytes (67 words) - date...)]
:What I want is to modify the "Page title matches" section have only:
:[Page title]
:[Search results data (ex: 457 bytes (67 words) - date...)] [[User:SDFM13|SDFM13]] ([[User talk:SDFM13|talk]]) 14:53, 5 July 2019 (UTC)
:It looks like you would have to use the [[Manual:Hooks/SpecialSearchResults|SpecialSearchResults hook]] to remove the body of the title matches.
:Note I have not done this before, so I'm just going by what I see in the code. <span style="color:#d30000">☠</span>[[User:MarkAHershberger|MarkAHershberger]]<span style="color:#d30000">☢</span>([[User_talk:MarkAHershberger|talk]])<span style="color:#d30000">☣</span> 19:11, 5 July 2019 (UTC)
:This part is in a div of class "searchresult". You could try adding <syntaxhighlight lang="css">.searchresult {display: none}
to MediaWiki:Common.css
I suppose you may want to check whether that class name appears elsewhere, and maybe it's different with CirrusSearch. Jonathan3 (talk) 20:26, 5 July 2019 (UTC)

why the "list of pages" does not appear in my "categories pages" ?

This page : https://www.mediawiki.org/wiki/Help:Categories

state that : Each of the pages in the Category namespace represents a so-called category, a grouping of related pages, and contains an index for the pages of its category.

Mine do not !


If I add a "[[Category:mycat]]" in an article and save it, "mycat" appear in the category list widget.

But when I clic the link and create the new category page, I do not have any article list.


Do I Forget something ?


I am on the "latest" library/mediawiki docker image, with the "timeless" skin and a Sqllite database. Thalion59fr (talk) 13:08, 5 July 2019 (UTC)

It sounds like you need to clear your job queue. See runJobs.php. MarkAHershberger(talk) 14:21, 5 July 2019 (UTC)
Thanks !
When I run "php maintenance/runJobs.php" inside the container, something happen !
A lot of lines like this are logged :
```
2019-07-05 16:30:30 htmlCacheUpdate Catégorie:Personnages table=templatelinks recursive=1 rootJobIsSelf=1 rootJobSignature=2e278efcfb5c373b229d7e94f9d10b222b801fe0 rootJobTimestamp=20190705163019 causeAction=page-create causeAgent=unknown requestId=9d0b4e75c86108e307038291 (id=20,timestamp=20190705163019) t=0 good
```
Somes about Pages, somes about Categories.
But the problem remains : I do not have the pages list on categories pages.
So I tryied with "php maintenance/rebuildall.php" and ... It works !
But I dare not imagine that this is the only way to do it : rebuild everything each time ...
I tryied with "php maintenance/refreshLinks.php" and it works too. But again ... I think it's too much.
Is there some reason why runJobs.php do not generate the links ? Thalion59fr (talk) 17:09, 5 July 2019 (UTC)
I really don't know. I would have expected runJobs.php to work. MarkAHershberger(talk) 19:21, 5 July 2019 (UTC)
I had a similar problem. I'll try to describe it, though I may get some details wrong, in the hope of answering your last question ("Is there some reason why runJobs.php do not generate the links ?").
In my case, for the period that categorisation was not working (i.e. categories would show up on content pages, but content pages wouldn't show up on category pages) it was because of an out-of-date extension. I guess the jobs had run, maybe with errors that I hadn't noticed, so runJobs.php made no difference. When I upgraded the extension, runJobs.php still would make no difference. It took rebuildall.php to fix the problem.
I hope that at some point you have change whatever was causing the problem, and that it all works as it should :-) Jonathan3 (talk) 20:18, 5 July 2019 (UTC)
Thanks, but it can not be my problem : I am on a "out of the box" Docker container without plugins (except "built in" ones)
Does it help if i make a step by step "how to reproduce" ? Thalion59fr (talk) 14:51, 6 July 2019 (UTC)
Yes, step-by-step would help. MarkAHershberger(talk) 16:02, 6 July 2019 (UTC)
I am really sorry, I can not reproduce the problem with the very last version :
- 1.33.0, published 3 days ago and tagged d673de9ba704
- mine was downloaded 4 days ago and tagged 14d5ff1e370c
(I am talking about docker images tags)
Better : it work without any cron-job !
So we can forget this, I guess Thalion59fr (talk) 19:49, 8 July 2019 (UTC)

I copied an Extension(Extension:VoteNY). 'javascript:void(0);' is appearing whenever I am trying to use it

So I copied this extension, line by line exploring its code and just made a clone of it 'Extension:P'.

The difference between both is that P does not have any special page ,and it does not have the voteStars functionality.

I also changed the table name ,but changed it in the copied code too...

On running update.php the table is being created in database, but when I am clicking on it, javascript:void(0); is appearing and no change in the table is happening.

Does anybody have any idea ? Plz tell..

Extension:VoteNY Falcopragati (talk) 16:17, 5 July 2019 (UTC)

We do not know what "it" is in "clicking on it". Please also include exact version information for MediaWiki itself and the extension itself. AKlapper (WMF) (talk) 17:46, 5 July 2019 (UTC)
oh sorry..
1.MediaWiki version-- 1.32.2
2.latest version of the Extension:VoteNY which is compatible with mediawiki-1.32.2
3.'it' is the 'vote' button .When I am hovering my curser on it, 'javascript:void(0)' is appearing on the bottom left corner of the browser window.
4.Code snippet from Javascript file of the extension-->
this.clickVote = function( TheVote, PageID ) {
( new mw.Api() ).postWithToken( 'edit', {
action: 'voteny',
format: 'json',
what: 'vote',
pageId: PageID,
voteValue: TheVote
} ).done( function( data ) {
$( '#PollVotes' ).html( data.voteny.result );
$( '#Answer' ).html(
'<a href="'''javascript:void(0);'''" class="vote-unvote-link">' +
mediaWiki.msg( 'voteny-unvote-link' ) + '</a>'
);
} );
}; Falcopragati (talk) 18:18, 5 July 2019 (UTC)
And what's exactly the problem? The browser seems to do what the javascript file defines? AKlapper (WMF) (talk) 18:38, 5 July 2019 (UTC)
'javascript:void(0)' does not appears while using the original 'Extension:VoteNY' ,On clicking the 'vote' button, the vote gets registered in the database.
But it appears when I use its copied version...
What does 'javascript:void(0)' signifies ? Falcopragati (talk) 18:43, 5 July 2019 (UTC)
As we do not know which exact code changes you performed it might be hard for anyone else to answer your question... AKlapper (WMF) (talk) 19:16, 5 July 2019 (UTC)
What Does JavaScript Void(0) Mean? MarkAHershberger(talk) 19:29, 5 July 2019 (UTC)

Patch file 1.32.3 to 1.33.0?

Is there a patch file from version 1.23.3 to 1.33.0? Can't find it.

Or do I have to patch to the rc.0. version of 1.33 first? If yes - cant find the patch file from 1.23.3 to the rc.0, either.

Kind regards,

Denis Giffeler (talk) 10:49, 6 July 2019 (UTC)

There is not, as 1.33.0 got just released and as 1.23.x has been unsupported for 24 months, so people who still ran 1.23 should have updated 24 months ago by latest. Malyacko (talk) 11:07, 6 July 2019 (UTC)
Oh b*** I messed up my question. It should read 1.32.3.

Giffeler (talk) 16:38, 6 July 2019 (UTC)
Why not just download the new 1.33 wiki and replace your old wiki? MarkAHershberger(talk) 16:23, 6 July 2019 (UTC)
Could do - just wondering why there is no patch file from 1.32.3 (sic!) to 1.33. Giffeler (talk) 16:39, 6 July 2019 (UTC)
I've actually been working on automating the releases and have noticed a few things missing. I missed this, though. Thanks for pointing it out. MarkAHershberger(talk) 18:35, 6 July 2019 (UTC)

Random page doesn't seem to work.

Recently I've setup a wiki on my server. The wiki only has 3 or 4 pages but the Random Page function doesn't seem to be working. Keeps redirecting me to the Main Page of the wiki.

Did I miss something during installation?

I'm pretty certain that I enabled Random Page during installation AndrePaulo9 (talk) 11:47, 6 July 2019 (UTC)

Read over the Help on the Random page feature. Note that if the pages you created are not in the main namespace (e.g. they have "Help:" in the name), then they won't be among the pages that are selected at random. See $wgContentNamespaces and the manual for more information. MarkAHershberger(talk) 16:13, 6 July 2019 (UTC)

I want to upload a HTML file

I keep getting error messages on upload.

I have changed settings in the local settings file, so the error message is now change from not being allowed to upload a html/text file to this:

"This file contains HTML or script code that may be erroneously interpreted by a web browser".

What do I have to do to make it work? Wertwijn (talk) 11:56, 6 July 2019 (UTC)

I do not know what a "HTML video file" is. Please provide a link to an example. Please elaborate. Please always provide MediaWiki version information. Please explain which exact "settings you changed in the local settings file". Malyacko (talk) 15:58, 6 July 2019 (UTC)
Sorry, I assumed the problem was known. So far I have followed the instructions on this post: https://www.mediawiki.org/w/index.php?title=Project%3ASupport%20desk/Flow/2019/07#c-Malyacko-2019-07-06T15%3A58%3A00.000Z-Wertwijn-2019-07-06T11%3A56%3A00.000Z Up to 2/3 down the page, where it says: "Even after all that (and it was needed), I still get the Upload Warning:This file contains HTML or script code that may be erroneously interpreted by a web browser".
This is also the message I get know when I try to upload my HTML file.
It is a HTML file which contains HTML5 and is in fact some kind of video, or so I have been told.
MediaWiki will not let me upload it on my own installation, which is on http://concepts.theartofmisunderstanding.org
Example of the HTML file: https://theartofmisunderstanding.org/wp-content/uploads/2019/06/Argument-classification-scheme.html
According to the version page, this is the version of MediaWiki I have installed
MediaWiki 1.32.2
PHP 7.3.6 (litespeed)
MariaDB 10.0.38-MariaDB-cll-lve
ICU 57.1

Wertwijn (talk) 16:51, 6 July 2019 (UTC)
If you really think that https://theartofmisunderstanding.org/wp-content/uploads/2019/06/Argument-classification-scheme.html links to a video file then please provide a direct link to that video file. Looking at the HTML source, it seems to only contain CSS and JavaScript. Feel free to correct me. Malyacko (talk) 17:59, 6 July 2019 (UTC)
Well, as I said, that is what I have been told. But if it is not a video file, then no matter. I want to upload it on my mediawiki, and I cannot. Wertwijn (talk) 18:13, 6 July 2019 (UTC)
See https://www.mediawiki.org/w/index.php?title=Project%3ASupport%20desk/Flow/2017/02#c-RedKnight7-2017-02-14T23%3A59%3A00.000Z-RedKnight7-2017-02-13T15%3A31%3A00.000Z and Manual:Importing external content#Converting content from HTML Malyacko (talk) 17:47, 7 July 2019 (UTC)
The first one is the same link I sent you in my previous post. I cannot get beyond 2/3 of the instructions. The statements are no longer in the same files, as the post says, and the instructions do not work anymore.
I will have a look at the second link on importing external content.

Wertwijn (talk) 18:17, 7 July 2019 (UTC)
I tried but I got stuck.
1) The Html2Wiki extension. The extension relies on Pandoc, which is a command-line document conversion tool. The extension allows users to import HTML content directly into the wiki, including images. Import entire websites, or complete web pages that you save from the browser (such as Google Docs).
2) Pandoc has an online demo. It has command line tool, integration to Python/Ruby and written in Haskell.
3) HTML2Mediawiki Java library with online demo.
Ad 1: Installed the extension, but now I get this error: "hi Html2Wiki requires Tidy.You can install the extension with something like sudo apt-get install php5-tidy
Please see the installation instructions at https://www.mediawiki.org/wiki/Extension:Html2Wiki for more info.".
I cannot make head or tail of the instructions.I also could not make head or tail of the instructions in the HTM2Wiki after the extension installation which talks about installing "composer". These are all instructions for programmers. I am not a programmer. I have installed MediaWiki on a hosted platform, and although I can change and upload settings-files, I cannot run commands on the server; I have no idea how.
Ad 2: I have tried to past the contents of my html file to this online tool, but it does not convert
Ad 3: The link does not work.
I have look at the older links but again the instructions are aimed at programmers who can run scripts on their servers.
Is there not a simple way to stop MediaWiki from blocking the upload? This is so very frustrating.

Wertwijn (talk) 18:54, 7 July 2019 (UTC)
hello? Wertwijn (talk) 19:42, 9 July 2019 (UTC)
Anyone home?

Wertwijn (talk) 16:56, 10 July 2019 (UTC)

Automatic numbering of footnotes

I have a MediaWiki 1.32.0 website with no external extensions whatsoever - I don't want to install any extension.

I need to add some manually-sorted footnotes to some articles and for that I can create:

template:1 with <sup>'''1'''</sup>

template:2 with <sup>'''2'''</sup>

template:3 with <sup>'''3'''</sup>

template:4 with <sup>'''4'''</sup>

template:5 with <sup>'''5'''</sup>

I could use these as footnotes 1,2,3,4,5

Instead creating five different templates, what will be a way to create one template and call it many times (without passing arguments and without any type of manual sorting --- sorting should be automatic)? 182.232.39.241 (talk) 22:08, 6 July 2019 (UTC)

I answered this question a few days ago, although you've added "without passing arguments and without any type of manual sorting --- sorting should be automatic".
I think you should just install the Cite extension. See the help on footnotes. MarkAHershberger(talk) 22:51, 6 July 2019 (UTC)

How do you implement page hit/view counters in current MediaWiki?

I have been searching around the past week trying to figure out how you're supposed to implement page hit/view counters in the current version of MediaWiki. The only extensions I can find seem outdated. Any solution? Anonymousguy8 (talk) 04:09, 7 July 2019 (UTC)

HitCounters should work. If it doesn't, let me know and I'll fix it. @Kghbln has filed a few bugs against it that I've fixed.
That said, it depends on the size of your wiki. Smaller wiki's might be fine using something like GoogleAnalytics. MarkAHershberger(talk) 18:22, 7 July 2019 (UTC)
Thanks Mark. I was confused by that page as it says "A fresh install in MW 1.26 and higher is not possible!" Should that line be removed then? Anonymousguy8 (talk) 22:02, 7 July 2019 (UTC)
I haven't tried, but I think it is possible.
Please try. If it turns out not to be possible, that is something I should fix. MarkAHershberger(talk) 02:10, 8 July 2019 (UTC)
Thanks Mark. Got it working a few weeks ago and everything has been going smoothly. I just have two follow up questions on the hit counting.
On the summary page it says:
  • The hit counts are stored in cache.
  • The visible hit count at the bottom of each page is updated only once per day. (Pages with hit count less than 100 are updated once per minute.)
  • If you refresh your browser on a wiki page, that hit is ignored.
How does the browser refresh hit ignoring work or how is it supposed to work? Ie. Does it temporarily log IPs and then ignoring recent views from the same IP or what? If so for what duration does it log/ignore and for what number of IPs?
I am curious about the mechanics or intention of this because I notice the behavior is somewhat inconsistent.
If I make a fresh page no one else is looking at and then shift-F5 to reload it a bunch of times, it does seem to manifest some of those into new views, but it varies. Eg. Once I might refresh 30 times and see 15 views added, then I might repeat again and see 1-2 views added.
I'm curious how this is working or supposed to be working so I can best understand the numbers going forward.
Second, do you know if there is any issue with counting accuracy if a wiki is using cloudflare or not? ie. Does cloudflare interfere with the counting?
Lastly, perhaps the line here: Extension:HitCounters
That says "Currently it is only possible to migrate wikis using MW 1.25 to use this extension. A fresh install in MW 1.26 and higher is not possible!" should be removed, as it seems to tell everyone this doesn't work in new versions and it still does seem to.
Thanks again for your help and your extension. Anonymousguy8 (talk) 01:51, 12 August 2019 (UTC)

Get WikiText from PageContentSaveComplete Hook

I'm using Manual:Hooks/PageContentSaveComplete to try to catch the updated text for a specific article name. Everything works except I need to drill $wikiPage down to the right text. How can I do that?

function onSaveComplete(&$wikiPage, &$user, $content, $summary, $isMinor, $isWatch, $section, &$flags, $revision, &$status, $baseRevId, $undidRevId){

	if($wikiPage->mTitle->mTextform == 'Specific article name') file_put_contents('/local/path/specific_article_name.text', $wikiPage);

	return true;}

$wgHooks['PageContentSaveComplete'][] = 'onSaveComplete';
72.216.234.213 (talk) 04:34, 7 July 2019 (UTC)
Do you mean "catch" or "cache"? Your code snippet looks more like catch, but I was just making sure.
A cleaned up version of your code that uses content the page's content. I have not tested this, but it should be a step in the right direction:
function onSaveComplete( $wikiPage, $user, $content ) {
  if($wikiPage->mTitle->mTextform == 'Specific article name' && $content instanceOf TextContent ) {
    file_put_contents('/local/path/specific_article_name.text', $content->getNativeData() );
  }
  return true;
}
$wgHooks['PageContentSaveComplete'][] = 'onSaveComplete';
MarkAHershberger(talk) 18:17, 7 July 2019 (UTC)

Alternative to extension "LinkTitles"?

Hello everyone,

I am looking for a simple way to automatically link words/text in my wiki to relevant articles.

E.g. my wiki contains an article about "engine oil" and so I want every other article that contains "engine oil" to automatically link to the article "engine oil".

The extension LinkTitles seems to do exactly that but is not compatible with the latest mediawiki version.

I wonder if there is an alternative or simply an easy way to do something similar? Utini (talk) 09:58, 7 July 2019 (UTC)

If you find an answer could you add it here? This is something I want to get done too.
I imagine it will be possible to write a simple extension using a hook (there are a few similar ones, e.g. Manual:Hooks/InternalParseBeforeLinks). In fact, that page has this in a discussion section: "...assume that some extension implements automatic linking of certain key-words, say names of known users".
In my case I want to use a regular expression to spot where to consider creating the automatic links. This is just a guess (probably wrong!) but I imagine it might be slow on a large wiki to look for every existing page title when displaying pages, so you might want to save a list of words (like "engine oil") somewhere, or pick a different hook and add the wikitext links to the page when it is saved. Jonathan3 (talk) 14:32, 7 July 2019 (UTC)
I like the idea of LinkTitles, but, you're right, it seems like it would take too long on a large wiki. I could see this being relatively quick if you can use Lingo to put suggested links in a table somewhere or, if you have a list of pages that you'd like the extension to consider linking to, you could even make a client-side tool to suggest or make links.
I'm guessing the reason it doesn't work with newer MW is because of the implementation of MCR. Maybe we can ask @CCicalese (WMF) what she thinks is needed to adapt LinkTitles. MarkAHershberger(talk) 18:06, 7 July 2019 (UTC)

What is ralouphie/getallheaders/src/getallheaders.php ?

I updated a few days ago my installation from 1.32.2 to 1.33. The site is ok after some troubles, but I have a last little issue to solve.

The arrays in 'vendor/composer/autoload_static.php' and in 'vendor/composer/autoload files.php', are both pointing to a library called '/ralouphie/getallheaders/src/getallheaders.php' which is not installed in the server (and also is not included in the downloadable package of MW 1.33).

Seems weird that MW call a file not provided with the installation, but it is what it is. To make my site work after the installation I had to disable these 2 rows in the 2 files. Not canonical, but only way to solve fast. ( in 11 years this is the first time I'm facing this issue that wasn't present in previous versions since 1.15 to 1.32.2). I never had this library in /vendor folder

Any idea or solution? Cesarinik (talk) 15:01, 7 July 2019 (UTC)

Are you using any extensions? MarkAHershberger(talk) 17:43, 7 July 2019 (UTC)
It is surprising that it is missing. You can download the contents of the vendor directory here. That will give you a tgz file whose contents can be put in the vendor directory. Note that it is the contents of the vendor directory and does not include the top level vendor, so you'll need to do something like:
public_html$ cd vendor
vendor$ tar xzf ~/FILEFROMLINK
MarkAHershberger(talk) 17:55, 7 July 2019 (UTC)
how did you update ? —TheDJ (Not WMF) (talkcontribs) 07:28, 8 July 2019 (UTC)
I know it's suprising, but I downloaded the official package via https://releases.wikimedia.org/mediawiki/1.33/mediawiki-1.33.0.tar.gz and upload everything via FTP with overwrite rule. At the end of the process, the folder ralouphie was not in the vendor folder .
Yesterday I tried to download the v.2.0.5 of ralouphie from Github and manually uploading it, then i reactivated the 2 rows previously disabled. Seems to work...

Cesarinik (talk) 08:44, 8 July 2019 (UTC)
The file is inside that tarball though.. So must have been a problem in the ftp transfer. —TheDJ (Not WMF) (talkcontribs) 09:12, 8 July 2019 (UTC)

Is a MediaWiki drop-down list selection possible?

I am using MW as a documentation platform for my company. Quite often repetitive data entry can be very time consuming. Is there a drop-down list function for MW that would allow for previous entries to be listed? Or, is there a drop-down list function that could reference a database with data that pertains to a specific table?

For instance, say I have 50 PCs, 5 servers, and 10 laptops that need to be entered into the documentation for a client. These would all be entered into the section regarding computers. Now, under that section in each new row there is a drop-down that you could select what type of computer it is (PC, server, laptop, etc.). Yesimthatj (talk) 17:28, 7 July 2019 (UTC)

Have you looked at tools like PageForms with Cargo and/or SemanticMediaWiki? MarkAHershberger(talk) 17:37, 7 July 2019 (UTC)
I have not. Thanks for the suggestion. I will look into them now Yesimthatj (talk) 17:46, 7 July 2019 (UTC)

Template:Multiple image

How do I create a template such as "Template:Multiple image" in MediaWiki? 109.64.224.6 (talk) 19:49, 7 July 2019 (UTC)

Go to the page named "Template:Multiple Image" on your wiki and click "create". MarkAHershberger(talk) 22:00, 7 July 2019 (UTC)
Yes, but how do I select the content of the template to display multiple images like in other MediaWiki websites? 109.64.224.6 (talk) 14:00, 8 July 2019 (UTC)
You'll have to provide a link to those other MediaWiki websites. AhmadF.Cheema (talk) 17:02, 8 July 2019 (UTC)
For example Template:Multiple image and all the linked languages from Wikipedia. 109.64.224.6 (talk) 05:27, 9 July 2019 (UTC)
Can't you export and then import that template into your Wiki? AhmadF.Cheema (talk) 05:44, 9 July 2019 (UTC)

Template parameters

I have a template "Template:BDS logo 320px". The value of the template is:


[--[File:BDS logo.png|320px|thumb|right|Boycott, Divestment, Sanctions (BDS)]--]


How do I convert "320px" to a parameter (such as width)? So I will be able to use the same template with different widths? 109.64.224.6 (talk) 20:01, 7 July 2019 (UTC)

Substitute {{{width|320px}}} for "320px" and then, when you use the template, whatever you give for your "width" parameter will be substituted. MarkAHershberger(talk) 21:59, 7 July 2019 (UTC)

Mobile M Version

Hello I would like to ask for your help because I have a wiki www.sourcewiki.org and I want it to also have a mobile version that auto-detects and leads to m.sourcewiki.org. Samueloweb (talk) 21:28, 7 July 2019 (UTC)

Have you looked at the MobileFrontend extension? MarkAHershberger(talk) 21:52, 7 July 2019 (UTC)
Yes Samueloweb (talk) 22:21, 7 July 2019 (UTC)
You could give me the code bro. Samueloweb (talk) 22:22, 7 July 2019 (UTC)
The code is in Extension:MobileFrontend (download link). AhmadF.Cheema (talk) 22:59, 7 July 2019 (UTC)

Error Updating Mediawiki

hello everyone I write to ask for help, what happens is that when I try to update mediawiki  

to the new version I get the error, I think it has to do with the installation of the /w directory to have /wiki

It appears

The following errors were found :

  • The installation files are missing hence cannot proceed with the upgrade Samueloweb (talk) 23:11, 7 July 2019 (UTC)
How do you try to update MediaWiki? AhmadF.Cheema (talk) 04:06, 8 July 2019 (UTC)

Old plugins notifications

I am in the process to install mediawiki in our company to have an internal wiki, I was looking for a plugin installer but I couldn't find anything (so I installed them manually as explained in the docs). My question is if there is any way to get notifications (preferably on the admin users) when there are new releases of the plugins / mediawiki. Aseques (talk) 09:01, 8 July 2019 (UTC)

Not for plugins but "announcements of new MediaWiki releases and security updates" should be available from mediawiki-announce. Also, see Communication#Mailing lists. AhmadF.Cheema (talk) 11:49, 8 July 2019 (UTC)
Thanks for your answer @AhmadF.Cheemabut I meant to get the notifucations when logging into the wikipedia as an admin account. Being this notification retreived automatically from mediawiki servers. Aseques (talk) 22:01, 22 July 2019 (UTC)
By "wikipedia", I'm assuming you mean you personal MediaWiki installation.
Regarding your question, I'm pretty sure such a system unfortunately doesn't exist yet. AhmadF.Cheema (talk) 04:35, 23 July 2019 (UTC)
That's what I needed, thanks anyway @AhmadF.Cheema Aseques (talk) 21:26, 30 July 2019 (UTC)

Allow lowercase pages

is it possible if not is there a way to display pages lowercase i am on 1.4 software Joseph2233 (talk) 10:19, 8 July 2019 (UTC)

MediaWiki version 1.4 has been unsupported since 2006. Please upgrade. Malyacko (talk) 10:58, 8 July 2019 (UTC)
After upgrade, see Manual:$wgCapitalLinks and Manual:$wgAllowDisplayTitle. AhmadF.Cheema (talk) 11:45, 8 July 2019 (UTC)

help please b ig gap in printed barcodes

i have a huge gap in printed barcodes for our library. we are closing the church down in the next ten days anmeone p;lease help, i have a huge gap in my barcodes 74.124.189.18 (talk) 16:48, 8 July 2019 (UTC)

and i need these barcodes to complete the labeling of our library! 74.124.189.18 (talk) 16:48, 8 July 2019 (UTC)
can someone email me or call me to help?
3366813483
please! library thing and tiny cat......missing 600 labels!!!
helP
sterling 74.124.189.18 (talk) 16:50, 8 July 2019 (UTC)
Wrong support forum.😕
This place is for help with the MediaWiki software. AhmadF.Cheema (talk) 17:01, 8 July 2019 (UTC)

how to delete wikimedia profile

Please remove my profile from your database immediately: *******@*****.com. I did login with an old password just now, and I attempted to find a way to remove my profile on the website. I could not and I searched quite a bit. Please remove me from this old and unused account. Thank you!


2600:1700:80:A8E0:195D:D79C:77F7:2E22 (talk) 21:29, 8 July 2019 (UTC)

This is not the right place to make such a request. None of us have this ability. MarkAHershberger(talk) 21:53, 8 July 2019 (UTC)
Note that if this is in reference to the right to be forgotten, then it appears that Wikimedia isn't really complying with that.
(Of course, I could be wrong and someone may correct me.) MarkAHershberger(talk) 21:58, 8 July 2019 (UTC)

Will installing extensions prevent me from easily upgrading MediaWiki in the future?

I have a very lightweight MediaWiki 1.32.0 website; as of now it has 0 external-extensions (by that I mean; extensions that don't come with that release).

I think to install Cite extension (which will change overall data of articles) and also EmailForm and MobileFrontend extensions but I am afraid that if I'll upgrade 1.32.0 to any later version, all Cite-based code and data would turn problematic or useless in articles and suddenly articles would start to have wired code inside them ("broken text") and also that the two other extensions EmailForm and MobileFrontend (and maybe also Cite itself) will cause PHP or SQL problems in upgrade, causing the site to become broken and need serious debugging (I am not a PHP/SQL developer and don't think I'll ever be hence I prefer to stay core-only as much as I can).

I love to upgrade programs, always, yet I don't plan to stay with 1.32.0 all my life, but the fear of having something broken due to upgrading when external-extensions are installed is eminent.

Please share your opinion on my fear, emphasizing the three extensions I have mentioned. 182.232.0.101 (talk) 00:17, 9 July 2019 (UTC)

Doesn't Extension:Cite come bundled with MediaWiki core too?
Regarding other extensions, as long as they continue to be updated by their developers there wouldn't be much problems with using and updating them on your Wiki. You really wouldn't need to be a "PHP/SQL developer" for any debugging.
When updating MediaWiki, you'll just have to update those extensions too; for potential debugging, adding just a few lines in LocalSettings.php will usually be all that's needed. AhmadF.Cheema (talk) 00:59, 9 July 2019 (UTC)
@AhmadF.Cheema if one wants to upgrade core and has some external-extensions that themselves need to be upgraded --- what should be upgraded first usually --- the core or the external-extensions? 182.232.0.101 (talk) 11:29, 9 July 2019 (UTC)
Core will be upgraded first, then extensions. In a way, I suppose, it doesn't matter as long as both are updated.
If the site stops working, debug lines will be placed in LocalSettings.php to get a descriptive error. AhmadF.Cheema (talk) 11:54, 9 July 2019 (UTC)
Thanks 182.232.0.101 (talk) 13:11, 9 July 2019 (UTC)

Missing articles after upgrading from 1.31.1 to 1.33?

Hi all,


I have been using MediaWiki for several years and it has always been working great, until the latest upgrade.

We currently are running version 1.31.1 and I decided to upgrade to version 1.33 yesterday. At first everything seemed in order.


However today, I was looking for an article and I couldn't find it anymore with the search (which normally pops up by using a certain search term). At first I thought I made a typo. But this is not the case. I found the article title, but when I click on it, it says the article does not exists anymore at all?


After diving a bit more into it, I noticed several more articles completely disappeared. Only the title exists, but the article itself is completely gone? Luckily I had a full backup (files and database) so I restored it and everything was fine again.


I never had this problem in the past when upgrading to a newer version. It only happened after this upgrade (from 1.31.1 to 1.33). My guess is, that it affects older created articles. Newer or recent articles are not affected by it. So it's strange. Anyone else experienced this? Or maybe know a solution for this?


Currently we are back to version 1.31.1 thanks to the backup I took. We use MediaWiki multiple times a day as it contains tutorials and other information for our company. So it's important we maintain all the articles.


Thanks in advance.


Regards


Running PHP 7.2 with MariaDB 10.1.

Also using the following extensions:

- Cite

- CiteThisPage

- ConfirmEdit'

- PdfHandler

- WikiEditor

- CSS.php

- VideoPlayer.php

- Widgets.php


(don't know if it's important, but thought I would mention it) HHawk79 (talk) 06:59, 9 July 2019 (UTC)

There were some changes made in how articles were stored. (See MCR for more info.) Perhaps these some db schema changes made caused the problem?
@CCicalese (WMF), have you seen anything like this? Do you think it would be a problem? MarkAHershberger(talk) 19:22, 9 July 2019 (UTC)
We have not, to my knowledge, seen anything like this. Is there anything special about the missing pages? For example, are there special characters in the page titles? Are any errors or warnings written to the error log when you try to access those pages? CCicalese (WMF) (talk) 19:43, 9 July 2019 (UTC)
What do you mean by "the title of the page exists"? Does that mean that links to the page where blue, but the content was gone? How about the page history? Was it empty?
With the new schema, there is a chain of references in the database that goes like this:
page.page_latest -> revision.rev_id <- slot.slot_revision_id, slot.slot_content_id -> content.content_id. Can you tell me what this chain looks like for any of the missing pages?
Also, were there any errors logged during update, or while trying to access the pages? Such errors may not be visible in the browser, see Manual:How_to_debug#PHP_errors. DKinzler (WMF) (talk) 21:11, 9 July 2019 (UTC)
If this continues to be a problem, please create a ticket in Phabricator to track this. CCicalese (WMF) (talk) 21:43, 9 July 2019 (UTC)
I have no clue what you all mean; I just updated our Mediawiki as I always do. Normally without any kind of issues. However this time some (older) articles only had the title and the rest inside the article was completely gone, no special characters, no nothing. All gone! No history, no nothing. G.O.N.E.!
Since we use this wiki multiple times a day, I didn't spend any time investigating. I only know what I saw. Therefor I installed the backup again, so everyone could use it once again.
I never heard of Phabricator, nor do I know how to use it. Anyways, we are running the backup now. I don't dare to update it again. LUCKILY I had a backup indeed... :S
And FYI version MediaWiki     1.31.1 has no issues whatsoever. But updating to 1.33 = OMG! HHawk79 (talk) 17:20, 10 July 2019 (UTC)
Can you provide rows from the page, revision, and text table that correspond to the "vanished" articles? That would help with investigating this issue.
Phabricator is our bug tracker, you can fit it at https://phabricator.wikimedia.org/. You can use the account you have here on this wiki to log in. DKinzler (WMF) (talk) 18:29, 10 July 2019 (UTC)
I will try to test it tomorrow on a subdomain. Is that easy to achieve? So we can use backed up version in the meantime.
And thank you for explaining. HHawk79 (talk) 19:44, 10 July 2019 (UTC)
Sorry for reviving an old forum thread. But I gave up in the end and I was in the hospital for several weeks (and finally also completely forgot about this).
Anyways. I decided to update the current installation from 1.31.1 to the latest stable version 1.34.
At first everything seemed okay. However I noticed again some articles are missing. No real special characters or such.
I looked at the upgrade log and I noticed the following:
Completed migration, updated 2341 row(s) with 33 new actor(s), 1370 error(s)
Beginning migration of archive.ar_user and archive.ar_user_text to archive.ar_actor
User name "Mr coko" is usable, cannot create an anonymous actor for it. Run maintenance/cleanupUsersWithNoId.php to fix this situation.
User name "Michel" is usable, cannot create an anonymous actor for it. Run maintenance/cleanupUsersWithNoId.php to fix this situation.
Okay, so I did some searching on this. Apparantly I need to run:
php cleanupUsersWithNoId.php  --dbuser=DBUSER--dbpass=DBPASSWORD --force --prefix=* --conf=../LocalSettings.php
Well again errors:
Beginning cleanup of revision
... rev_timestamp=20150617134238 rev_id=381
... rev_timestamp=20150722094638 rev_id=518
... rev_timestamp=20151127085305 rev_id=642
... rev_timestamp=20160426071624 rev_id=747
... rev_timestamp=20170427053837 rev_id=1354
... rev_timestamp=20171025135944 rev_id=1863
... rev_timestamp=20180626112633 rev_id=2994
... rev_timestamp=20191210182547 rev_id=3718
Completed cleanup, assigned 0 and prefixed 0 row(s)
Beginning cleanup of archive
Wikimedia\Rdbms\DBQueryError from line 1603 of /var/www/vhosts/sub.domain.com/httpdocs/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  ar_id,ar_user,ar_user_text,ar_id  FROM `archive`    WHERE (1=1)  ORDER BY ar_id LIMIT 100
Function: CleanupUsersWithNoId::cleanup
Error: 1054 Unknown column 'ar_user' in 'field list' (localhost)
#0 /var/www/vhosts/sub.domain.com/httpdocs/includes/libs/rdbms/database/Database.php(1574): Wikimedia\Rdbms\Database->getQueryExceptionAndLog('Unknown column ...', 1054, 'SELECT  ar_id,a...', 'CleanupUsersWit...')
#1 /var/www/vhosts/sub.domain.com/httpdocs/includes/libs/rdbms/database/Database.php(1152): Wikimedia\Rdbms\Database->reportQueryError('Unknown column ...', 1054, 'SELECT  ar_id,a...', 'CleanupUsersWit...', false)
#2 /var/www/vhosts/sub.domain.com/httpdocs/includes/libs/rdbms/database/Database.php(1807): Wikimedia\Rdbms\Database->query('SELECT  ar_id,a...', 'CleanupUsersWit...')
#3 /var/www/vhosts/sub.domain.com/httpdocs/includes/libs/rdbms/database/DBConnRef.php(68): Wikimedia\Rdbms\Database->select('archive', Array, Array, 'CleanupUsersWit...', Array)
#4 /var/www/vhosts/sub.domain.com/httpdocs/includes/libs/rdbms/database/DBConnRef.php(315): Wikimedia\Rdbms\DBConnRef->__call('select', Array)
#5 /var/www/vhosts/sub.domain.com/httpdocs/maintenance/cleanupUsersWithNoId.php(153): Wikimedia\Rdbms\DBConnRef->select('archive', Array, Array, 'CleanupUsersWit...', Array)
#6 /var/www/vhosts/sub.domain.com/httpdocs/maintenance/cleanupUsersWithNoId.php(63): CleanupUsersWithNoId->cleanup('archive', Array, 'ar_user', 'ar_user_text', Array, Array)
#7 /var/www/vhosts/sub.domain.com/httpdocs/maintenance/Maintenance.php(1746): CleanupUsersWithNoId->doDBUpdates()
#8 /var/www/vhosts/sub.domain.com/httpdocs/maintenance/doMaintenance.php(99): LoggedUpdateMaintenance->execute()
#9 /var/www/vhosts/sub.domain.com/httpdocs/maintenance/cleanupUsersWithNoId.php(212): require_once('/var/www/vhosts...')
Apparently you have to do that before running php update?
Anyways, reverted to the previous database and ran it again. This time no errors, but also not much happening:
Beginning cleanup of revision
... rev_timestamp=20150617134238 rev_id=381
... rev_timestamp=20150722094638 rev_id=518
... rev_timestamp=20151127085305 rev_id=642
... rev_timestamp=20160426071624 rev_id=747
... rev_timestamp=20170427053837 rev_id=1354
... rev_timestamp=20171025135944 rev_id=1863
... rev_timestamp=20180626112633 rev_id=2994
... rev_timestamp=20191210182547 rev_id=3718
Completed cleanup, assigned 0 and prefixed 0 row(s)
Beginning cleanup of archive
... ar_id=72
Completed cleanup, assigned 0 and prefixed 0 row(s)
Beginning cleanup of logging
Completed cleanup, assigned 0 and prefixed 0 row(s)
Beginning cleanup of image
Completed cleanup, assigned 0 and prefixed 0 row(s)
Beginning cleanup of oldimage
... oi_name=Da_bfm_settings.png oi_timestamp=20170116082129
Completed cleanup, assigned 0 and prefixed 0 row(s)
Beginning cleanup of filearchive
... fa_id=4
Completed cleanup, assigned 0 and prefixed 0 row(s)
Beginning cleanup of ipblocks
Completed cleanup, assigned 0 and prefixed 0 row(s)
Beginning cleanup of recentchanges
... rc_id=3706
... rc_id=3779
Completed cleanup, assigned 0 and prefixed 0 row(s)
Running the update (once again) resulted in the exact same errors. Catch-22?
Why is it so difficult to update Mediawiki 1.31.1 to 1.34? I really do not understand. I haven't had these issues with prior (pre 1.31.x) updates.
Anyways, I will restore everything back and redo everything again. And update from 1.31 to 1.32...... 1.34.
Maybe that will work. I will also run that cleanupUsersWithNoId.php command on my restored 1.31.1 installation.
No clue. Maybe it helps. HHawk79 (talk) 11:56, 22 January 2020 (UTC)
Okay I reverted back to my backup, which was version 1.31.1
I also ran update.php on it and got the same "errors" in regards to: User name "Michel" is usable, cannot create an anonymous actor for it. Run maintenance/cleanupUsersWithNoId.php to fix this situation.
Partial result of this user:
User name "Michel" is usable, cannot create an anonymous actor for it. Run maintenance/cleanupUsersWithNoId.php to fix this situation.
... rev_id=849
... rev_id=968
... rev_id=1075
... rev_id=1179
... rev_id=1279
... rev_id=1414
... rev_id=1514
... rev_id=1622
... rev_id=1724
... rev_id=1926
... rev_id=1998
Completed migration, updated 0 row(s) with 0 new actor(s), 1370 error(s)
I am guessing the above causes the issues with missing articles when I update to 1.34 (or previously, as in my original post to 1.33).
No clue on how to solve this. HHawk79 (talk) 12:14, 22 January 2020 (UTC)
Found a similar issue on something called zetawiki.com: https://zetawiki.com/wiki/User_name_%22John%22_is_usable,_cannot_create_an_anonymous_actor_for_it._Run_maintenance/cleanupUsersWithNoId.php_to_fix_this_situation.
It seems to relate to my issue, but the SQL command does not show any results back. Will try a few things. HHawk79 (talk) 12:30, 22 January 2020 (UTC)
Well dunno what did it; I experimented with several things from different sources:
https://zetawiki.com/wiki/User_name_%22John%22_is_usable,_cannot_create_an_anonymous_actor_for_it._Run_maintenance/cleanupUsersWithNoId.php_to_fix_this_situation
and:
https://phabricator.wikimedia.org/T206859
Followed by running various commands from bash.
Dunno what helped, but now running version 1.34 with all my articles still available.
Still no clue why this happend.
Still getting several messages like this: User name "XXX" is usable, cannot create an anonymous actor for it
But apparently no errors. Is there a way to solve those messages for future updates? Or can they safely be ignored (I rather not, as those gave apparently issues in the past).
Regards HHawk79 (talk) 14:19, 22 January 2020 (UTC)

Having a Problem Installing On WIN 10 Parsoid and Visual Editor

Hello,


First of all I wanted to apologize for accidentelly creating an article on this website, because I thought, that I had run successful visual editor., then I realized, it was not localhost, it was this website.


I have now installed Windows x64 1903.

IIS is disabled by default by windows, so I had not installed it.


Installed NodeJS x86 Version 10 and Git x86.


1.) Installed Mediawiki by using a bitnami stack (installed in "C:\Bitnami\mediawiki-1.33.0-0\")

So the Htdocs folder is located in "C:\Bitnami\mediawiki-1.33.0-0\apps\mediawiki\htdocs"


2.) I followed the bitnami instructions, but I failed, since it was too old, that it could not Parsoid download, because the link was broken.


3.) Now I changed my mind and followed mediawikis desciption:


For the record my username is acutally "PC"


npm install --global --production windows-build-tools
cd %USERPROFILE%
npm install parsoid
%USERPROFILE%\node_modules\parsoid\

Copy the default config and configure parsoid

copy %USERPROFILE%\node_modules\parsoid\localsettings.example.js %USERPROFILE%\node_modules\parsoid\localsettings.js
copy %USERPROFILE%\node_modules\parsoid\config.example.yaml %USERPROFILE%\node_modules\parsoid\config.yaml
cd %APPDATA%\npm\node_modules\parsoid
node bin/server.js



After that the file config.yaml has not been copied (even the cmd states copied, so I copied it myself to the folder:


wfLoadExtension( 'VisualEditor' );

// Enable by default for everybody

$wgDefaultUserOptions['visualeditor-enable'] = 1;

// Optional: Set VisualEditor as the default for anonymous users

// otherwise they will have to switch to VE

// $wgDefaultUserOptions['visualeditor-editor'] = "visualeditor";

// Don't allow users to disable it

$wgHiddenPrefs[] = 'visualeditor-enable';

// OPTIONAL: Enable VisualEditor's experimental code features

#$wgDefaultUserOptions['visualeditor-enable-experimental'] = 1;

$wgVirtualRestConfig['modules']['parsoid'] = array(

    'url' => 'http://localhost:8000',

    'domain' => 'localhost',

    'prefix' => 'localhost'

);

the api.php was not located at "'http://localhost/api.php'" so I changed it myself to "'http://localhost/mediawiki/api.php'"

Localsettings.php is following after the end:



Parsoid installed on: C:\Users\PC\node_modules\parsoid

Mediawiki is installed on C:\Bitnami\mediawiki-1.33.0-0\apps\mediawiki\htdocs

Visualeditor I have downloaded for 1.33 and I have extracted into "C:\Bitnami\mediawiki-1.33.0-0\apps\mediawiki\htdocs\extensions\VisualEditor"



Now if I click on "Create" on Mediawiki, then it will ask me to use Visual Editor, it will load fully.

Everything works.

Then if hit save, it will tell me

"Something went wrong

(curl error: 7) Couldn't connect to server"


Please help me with this. Sevib1595 (talk) 07:55, 9 July 2019 (UTC)

The yaml file is this:
# This is a sample configuration file
#
# Copy this file to config.yaml and edit that file to fit your needs.
#
# Also see:
# - `npm start -- -h` for more information about passing config files via
#   the commandline.
# - lib/config/ParsoidConfig.js for all the properties that you can configure
#   here. Not all properties are documented here.
# The number of http workers (as opposed to `cpu_workers` below)
#num_workers: 1
worker_heartbeat_timeout: 300000
logging:
    level: info
#metrics:
#    type: log
services:
  - module: lib/index.js
    entrypoint: apiServiceWorker
    conf:
        # For backwards compatibility, and to continue to support non-static
        # configs for the time being, optionally provide a path to a
        # localsettings.js file.  See localsettings.example.js
        #localsettings: ./localsettings.js
        # Set your own user-agent string
        # Otherwise, defaults to:
        #   'Parsoid/<current-version-defined-in-package.json>'
        #userAgent: 'My-User-Agent-String'
        # Configure Parsoid to point to your MediaWiki instances.
        mwApis:
          # This is the only required parameter,
          # the URL of you MediaWiki API endpoint.
          uri: 'http://localhost/mediawiki/api.php'
          # The "domain" is used for communication with Visual Editor
          # and RESTBase.  It defaults to the hostname portion of
          # the `uri` property above, but you can manually set it
          # to an arbitrary string. It must match the "domain" set
          # in $wgVirtualRestConfig.
          domain: 'localhost'  # optional
          # To specify a proxy (or proxy headers) specific to this prefix
          # (which overrides defaultAPIProxyURI). Alternatively, set `proxy`
          # to `null` to override and force no proxying when a default proxy
          # has been set.
          #proxy:
          #    uri: 'http://my.proxy:1234/'
          #    headers:  # optional
          #        'X-Forwarded-Proto': 'https'
          # See below, defaults to true.
          #strictSSL: false
        # Enable using compute workers to parse requests.
        #useWorker: true
        # The number of workers in the pool spawned by each http worker to
        # call out for parsing.  Defaults to:
        #   ceil(number of cpus / `num_workers`) + 1
        #cpu_workers: 1
        # We pre-define wikipedias as 'enwiki', 'dewiki' etc. Similarly
        # for other projects: 'enwiktionary', 'enwikiquote', 'enwikibooks',
        # 'enwikivoyage' etc.
        # The default for this is false. Uncomment the line below if you want
        # to load WMF's config for wikipedias, etc.
        #loadWMF: true
        # A default proxy to connect to the API endpoints.
        # Default: undefined (no proxying).
        # Overridden by per-wiki proxy config in setMwApi.
        #defaultAPIProxyURI: 'http://proxy.example.org:8080'
        # Enable debug mode (prints extra debugging messages)
        #debug: true
        # Use the PHP preprocessor to expand templates via the MW API (default true)
        #usePHPPreProcessor: false
        # Use selective serialization (default false)
        #useSelser: true
        # Allow cross-domain requests to the API (default '*')
        # Sets Access-Control-Allow-Origin header
        # disable:
        #allowCORS: false
        # restrict:
        #allowCORS: 'some.domain.org'
        # Allow override of port/interface:
        #serverPort: 8000
        #serverInterface: '127.0.0.1'
        # Enable linting of some wikitext errors to the log
        #linting: true
        #linter:
        #  sendAPI: false # Send lint errors to MW API instead of to the log
        #  apiSampling: 10 # Sampling rate (1 / 10)
        # Require SSL certificates to be valid (default true)
        # Set to false when using self-signed SSL certificates
        # Note that this can also be applied per wiki in the mwApis above
        #strictSSL: false
        # Use a different server for CSS style modules.
        # Leaving it undefined (the default) will use the same URI as the MW API,
        # changing api.php for load.php.
        #modulesLoadURI: 'http://example.org/load.php' Sevib1595 (talk) 07:57, 9 July 2019 (UTC)
Also on Chrome Developer toolkit i looked, following it states:
/mediawiki/index.php?title=Was&veaction=edit#null:1 Failed to load resource: the server responded with a status of 404 (Not Found)
The full log:
load.php?debug=false&lang=en&modules=jquery&skin=vector&version=0w5wrgy:141 JQMIGRATE: Migrate is installed with logging active, version 3.0.1
VM49:108 This page is using the deprecated ResourceLoader module "jquery.throttle-debounce".
Please use OO.ui.throttle/debounce instead. See https://phabricator.wikimedia.org/T213426
(anonymous) @ VM49:108
runScript @ load.php?lang=en&modules=startup&only=scripts&skin=vector:13
execute @ load.php?lang=en&modules=startup&only=scripts&skin=vector:15
doPropagation @ load.php?lang=en&modules=startup&only=scripts&skin=vector:7
/mediawiki/index.php?title=Was&veaction=edit#null:1 Failed to load resource: the server responded with a status of 404 (Not Found) Sevib1595 (talk) 08:27, 9 July 2019 (UTC)

Query, how often a template is called

Dear All,

It would be convenient for me to query automatically, how often a template is called within a page. Is there a command to do so?

Thank you in advance!

Yours, Ciciban (talk) 08:06, 9 July 2019 (UTC)

No, this information isn't tracked (only IF a template is used on a page). —TheDJ (Not WMF) (talkcontribs) 20:59, 9 July 2019 (UTC)
I wonder if you could get the Cargo extension to store full page text (see Extension:Cargo/Storing_data#Storing_page_data) then do a SQL query to count how many times the template call appears in the wikitext. Jonathan3 (talk) 22:22, 9 July 2019 (UTC)

Sites only visible for designated Users?

Hello,

Is it possible to make special Sites only visible for designated Users e.g. Administrator only?

Ich have build a wiki for my Users, now I want a restricted area which is only visible for me an my collegues. Is that possible?


Thank 80.151.250.142 (talk) 08:19, 9 July 2019 (UTC)

Sure. Please see Manual:Preventing access and Extension:Lockdown. 94rain Talk 08:21, 9 July 2019 (UTC)

Parsing a DynamicPageList

Dear All,

I have Ext:DynamicPageList (Wikimedia) installed.

Is there any way to get the output list parsed within a template?

Essentially I need it to check, if a page X calls a template Y. If you know the direct way, all the better. It sounds so trivial.

Thanks – Ciciban (talk) 10:47, 9 July 2019 (UTC)

If I understand your question correctly, you could do this with Extension:DynamicPageList3. See this manual page. Maybe there is something similar for the extension you have installed. Jonathan3 (talk) 22:17, 9 July 2019 (UTC)
Thanks.
As a pitty I am not the admin. So Ext:DynamicPageList (Wikimedia) is a datum. So if there is a way in that version, let me know.
Ciciban (talk) 09:32, 10 July 2019 (UTC)
Some older version of Lua were able to do this but not modern versions.
Generally speaking, no its not possible to parse the output of an extension tag. Bawolff (talk) 04:44, 16 July 2019 (UTC)

How to make a webpage accessible only for a certain user?

In MediaWiki 1.32.0 I have a webpage I am working on as the admin of a website; a webpage that describes my personal life. From comfortability reasons I'd like to edit it through MediaWiki itself.

I don't want any other user (registered or anonymous) to access that webpage.

I already disallowed the webpage in robots.txt but people could still access it from "recent changes" or similar chapter.

How to totally block entrance to the webpage if they are not the first user in the wiki (as I am)? 182.232.0.101 (talk) 12:07, 9 July 2019 (UTC)

See Manual:Preventing access#Restrict viewing Malyacko (talk) 14:58, 9 July 2019 (UTC)
@Malyacko Sadly I didn't get an answer there per my particular need and also, the linked extension there (Oversight) was archived. 182.232.0.157 (talk) 23:05, 9 July 2019 (UTC)
Oh sorry - @Malyacko it's good enough for me, please delete this comment and the previous one I wrote. 182.232.0.157 (talk) 23:31, 9 July 2019 (UTC)
@Malyacko it doesn't include a solution but makes the point that I should adjust to the philosophy behind MediaWiki if I don't want to to change the PHP. I hope these comments will be deleted. 182.232.0.157 (talk) 23:36, 9 July 2019 (UTC)
If you want to restrict all visits to the entire Wiki other than yours, then doing so is straightforward through a private wiki.
If you want to customize access on a per user and per page basis then you'll probably need to "adjust to the philosophy behind MediaWiki". Customized access can be done, but it won't be reliable.
One reliable solution would be to Restrict editing of an entire namespace and use that for your personal space.

AhmadF.Cheema (talk) 01:13, 10 July 2019 (UTC)

sending Email to all registered users

Is ther a possibilty to send an Email via the wiki to all registered users, for Ex: if I want to notify all users of anything new ? 2610S (talk) 17:11, 9 July 2019 (UTC)

If you can can perform SQL queries on the DB then you can extract their emails from the user table. MarkAHershberger(talk) 19:16, 9 July 2019 (UTC)
I have a list of all emails via LastUserLogin, but I want a option sending a email via wiki and not from own email address 2610S (talk) 20:57, 9 July 2019 (UTC)
Try Extension:Newsletter. 94rain Talk 15:35, 14 July 2019 (UTC)

Numeração de Indice

Como faço para que um titulo mostre ao lado dele o numero que ele tem no Indice? Gustavoambrosio (talk) 18:47, 9 July 2019 (UTC)

Por exemplo,
tenho um texto com 6 títulos ou seja numeração de 1 a 6,
como faço para que o Título de numero 1 apareça dessa forma:
1.Titulo1
se eu fizer isso manualmente digitando o numero 1. ao lado do titulo no indice ele fica dessa forma:
Indice
1 1.Titulo1
2 2.Titulo2 Gustavoambrosio (talk) 18:51, 9 July 2019 (UTC)
See NumberedHeadings. MarkAHershberger(talk) 19:14, 9 July 2019 (UTC)

Cannot access the database: :real_connect(): (HY000/2054): The server requested authentication method unknown to the client.


Cannot access the database: :real_connect(): (HY000/2054): The server requested authentication method unknown to the client.

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


I am following the checklist for the Windows Server 2016 Installation, I have done the optional step for IIS as well. However I get this error after following the checklist exactly as it is ? please assist I receive the error above. Whytewolfgeralt (talk) 21:31, 9 July 2019 (UTC)
Message: mysqli::real_connect(): The server requested authentication method unknown to the client [caching_sha2_password] 103.76.211.187 (talk) 12:15, 24 July 2020 (UTC)
You need to change the encryption on the mysql side. MarkAHershberger(talk) 15:30, 24 July 2020 (UTC)
What version of php and mysql do you have? MarkAHershberger(talk) 21:56, 9 July 2019 (UTC)
php 5.6 & php 7.2 And mysql 8.0.21 103.76.211.187 (talk) 12:16, 24 July 2020 (UTC)
Also see here and here for a hint. MarkAHershberger(talk) 22:01, 9 July 2019 (UTC)
PHP 7.3.6 mySQL 8.0
After reading the articles I am confused if I should downgrade PHP or try a simple password for the MySQL Server ? Whytewolfgeralt (talk) 13:24, 10 July 2019 (UTC)
The problem isn't PHP, it is MySQL 8. I think changing your password so it uses the new format, might be enough to fix the problem. Read over the answers on the second link to Stack Overflow which suggest the same thing. MarkAHershberger(talk) 16:47, 10 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

update.php Error: 1054 Unknown column 'ar_comment_id' in 'where clause' (localhost)

Seems to be a new field, should this be covered in update.php?


Trying to migrate to a new install of 1.33.0 on a new server from 1.32.1.

Mysql dump


On running update.php I'm getting the above. Manually running migrateactors.php doesn't seem to do it either.


The way our setup works it's a bit awkward to do it another way but guess I can install 1.32.1 on the new server and patch up if needed. But should I have to please?


It could also be something weird in our LocalSettings.php as this has built up over time and I'm aiming to start again, but wanted to rule out the update.php and ask for advice first please.


Full output of update.php
MediaWiki 1.33.0 Updater
Your composer.lock file is up to date with current dependencies!
Going to run database updates for wiki-wiki_
Depending on the size of your database this may take a while!
Abort with control-c in the next five seconds (skip this countdown with --quick) ... 0
Turning off Content Handler DB fields for this part of upgrade.
...have ipb_id field in ipblocks table.
...have ipb_expiry field in ipblocks table.
...already have interwiki table
...indexes seem up to 20031107 standards.
...have rc_type field in recentchanges table.
...index new_name_timestamp already set on recentchanges table.
...have user_real_name field in user table.
...querycache table already exists.
...objectcache table already exists.
...categorylinks table already exists.
...have pagelinks; skipping old links table updates
...il_from OK
...have rc_ip field in recentchanges table.
...index PRIMARY already set on image table.
...have rc_id field in recentchanges table.
...have rc_patrolled field in recentchanges table.
...logging table already exists.
...have user_token field in user table.
...have wl_notificationtimestamp field in watchlist table.
...watchlist talk page rows already present.
...user table does not contain user_emailauthenticationtimestamp field.
...page table already exists.
...have log_params field in logging table.
...logging table has correct log_title encoding.
...have ar_rev_id field in archive table.
...have page_len field in page table.
...revision table does not contain inverse_timestamp field.
...have rev_text_id field in revision table.
...have rev_deleted field in revision table.
...have img_width field in image table.
...have img_metadata field in image table.
...have user_email_token field in user table.
...have ar_text_id field in archive table.
...page_namespace is already a full int (int(11)).
...ar_namespace is already a full int (int(11)).
...rc_namespace is already a full int (int(11)).
...wl_namespace is already a full int (int(11)).
...qc_namespace is already a full int (int(11)).
...log_namespace is already a full int (int(11)).
...have img_media_type field in image table.
...already have pagelinks table.
...image table does not contain img_type field.
...already have unique user_name index.
...user_groups table exists and is in current format.
...have ss_total_pages field in site_stats table.
...user_newtalk table already exists.
...have iw_trans field in interwiki table.
...wl_notificationtimestamp is already nullable.
...index times already set on logging table.
...have ipb_range_start field in ipblocks table.
...no page_random rows needed to be set
...have user_registration field in user table.
...templatelinks table already exists
...externallinks table already exists.
...job table already exists.
...have ss_images field in site_stats table.
...langlinks table already exists.
...querycache_info table already exists.
...filearchive table already exists.
...have ipb_anon_only field in ipblocks table.
...index rc_ns_usertext already set on recentchanges table.
...index rc_user_text already set on recentchanges table.
...have user_newpass_time field in user table.
...redirect table already exists.
...querycachetwo table already exists.
...have ipb_enable_autoblock field in ipblocks table.
...index pl_namespace on table pagelinks includes field pl_from.
...index tl_namespace on table templatelinks includes field tl_from.
...index il_to on table imagelinks includes field il_from.
...have rc_old_len field in recentchanges table.
...have user_editcount field in user table.
...page_restrictions table already exists.
...have log_id field in logging table.
...have rev_parent_id field in revision table.
...have pr_id field in page_restrictions table.
...have rev_len field in revision table.
...have rc_deleted field in recentchanges table.
...have log_deleted field in logging table.
...have ar_deleted field in archive table.
...have ipb_deleted field in ipblocks table.
...have fa_deleted field in filearchive table.
...have ar_len field in archive table.
...have ipb_block_email field in ipblocks table.
...index cl_sortkey on table categorylinks includes field cl_from.
...have oi_metadata field in oldimage table.
...index usertext_timestamp already set on archive table.
...index img_usertext_timestamp already set on image table.
...index oi_usertext_timestamp already set on oldimage table.
...have ar_page_id field in archive table.
...have img_sha1 field in image table.
...protected_titles table already exists.
...have ipb_by_text field in ipblocks table.
...page_props table already exists.
...updatelog table already exists.
...category table already exists.
...category table already populated.
...have ar_parent_id field in archive table.
...have user_last_timestamp field in user_newtalk table.
...protected_titles table has correct pt_title encoding.
...have ss_active_users field in site_stats table.
...ss_active_users user count set...
...have ipb_allow_usertalk field in ipblocks table.
...change_tag table already exists.
...user_properties table already exists.
...log_search table already exists.
...have log_user_text field in logging table.
...l10n_cache table already exists.
...ct_rc_id key doesn't exist.
...have rd_interwiki field in redirect table.
...*_mime_minor fields are already long enough.
...iwlinks table already exists.
...index iwl_prefix_title_from already set on iwlinks table.
...have ul_value field in updatelog table.
...have iw_api field in interwiki table.
...iwl_prefix key doesn't exist.
...have cl_collation field in categorylinks table.
...categorylinks up-to-date.
...module_deps table already exists.
...ar_page_revid key doesn't exist.
...skipping index ar_revid because index ar_revid_uniq already set on archive table.
...ll_lang is up-to-date.
...user_last_timestamp is already nullable.
...index user_email already set on user table.
...up_property in table user_properties already modified by patch patch-up_property.sql.
...uploadstash table already exists.
...user_former_groups table already exists.
...have rev_sha1 field in revision table.
...batch conversion of user_options: nothing to migrate. done.
...user table does not contain user_options field.
...have ar_sha1 field in archive table.
...index page_redirect_namespace_len already set on page table.
...have us_chunk_inx field in uploadstash table.
...have job_timestamp field in job table.
...index page_user_timestamp already set on revision table.
...have ipb_parent_block_id field in ipblocks table.
...index ipb_parent_block_id already set on ipblocks table.
...category table does not contain cat_hidden field.
...have rev_content_format field in revision table.
...have rev_content_model field in revision table.
...have ar_content_format field in archive table.
...have ar_content_model field in archive table.
...have page_content_model field in page table.
Content Handler DB fields should be usable now.
...site_stats table does not contain ss_admins field.
...recentchanges table does not contain rc_moved_to_title field.
...sites table already exists.
...have fa_sha1 field in filearchive table.
...have job_token field in job table.
...have job_attempts field in job table.
...have us_props field in uploadstash table.
...ug_group in table user_groups already modified by patch patch-ug_group-length-increase-255.sql.
...ufg_group in table user_former_groups already modified by patch patch-ufg_group-length-increase-255.sql.
...index pp_propname_page already set on page_props table.
...index img_media_mime already set on image table.
...iwl_prefix_title_from index is already non-UNIQUE.
...index iwl_prefix_from_title already set on iwlinks table.
...have ar_id field in archive table.
...have el_id field in externallinks table.
...have rc_source field in recentchanges table.
...index log_user_text_type_time already set on logging table.
...index log_user_text_time already set on logging table.
...have page_links_updated field in page table.
...have user_password_expires field in user table.
...have pp_sortkey field in page_props table.
...recentchanges table does not contain rc_cur_time field.
...index wl_user_notificationtimestamp already set on watchlist table.
...have page_lang field in page table.
...have pl_from_namespace field in pagelinks table.
...have tl_from_namespace field in templatelinks table.
...have il_from_namespace field in imagelinks table.
...img_major_mime in table image already modified by patch patch-img_major_mime-chemical.sql.
...oi_major_mime in table oldimage already modified by patch patch-oi_major_mime-chemical.sql.
...fa_major_mime in table filearchive already modified by patch patch-fa_major_mime-chemical.sql.
...comment fields are up to date.
...hitcounter doesn't exist.
...site_stats table does not contain ss_total_views field.
...page table does not contain page_counter field.
...msg_resource_links doesn't exist.
...msg_resource doesn't exist.
...bot_passwords table already exists.
...have wl_id field in watchlist table.
...cl_collation key doesn't exist.
...index cl_collation_ext already set on categorylinks table.
...collations up-to-date.
...index rc_name_type_patrolled_timestamp already set on recentchanges table.
...rev_page_id index already non-unique.
...pl_namespace, tl_namespace, il_to indices are already non-UNIQUE.
...have ct_id field in change_tag table.
...rc_ip in table recentchanges already modified by patch patch-rc_ip_modify.sql.
...index usertext_timestamp already set on archive table.
...have el_index_60 field in externallinks table.
...ug_user_group key doesn't exist.
...have ug_expiry field in user_groups table.
...index img_user_timestamp already set on image table.
...img_media_type in table image already modified by patch patch-add-3d.sql.
...ip_changes table already exists.
...index PRIMARY already set on categorylinks table.
...index PRIMARY already set on templatelinks table.
...index PRIMARY already set on pagelinks table.
...index PRIMARY already set on text table.
...index PRIMARY already set on imagelinks table.
...index PRIMARY already set on iwlinks table.
...index PRIMARY already set on langlinks table.
...index PRIMARY already set on log_search table.
...index PRIMARY already set on module_deps table.
...index PRIMARY already set on objectcache table.
...index PRIMARY already set on querycache_info table.
...index PRIMARY already set on site_stats table.
...index PRIMARY already set on user_former_groups table.
...index PRIMARY already set on user_properties table.
...comment table already exists.
...have img_description_id field in image table.
Migrating comments to the 'comments' table, printing progress markers. For large
databases, you may want to hit Ctrl-C and do this manually with
maintenance/migrateComments.php.
Beginning migration of revision.rev_comment to revision_comment_temp.revcomment_comment_id
Completed migration, updated 0 row(s) with 0 new comment(s)
Beginning migration of archive.ar_comment to archive.ar_comment_id
[034d7b4d9242fb01ccc68f67] [no req]   Wikimedia\Rdbms\DBQueryError from line 1587 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  ar_id,ar_comment  FROM `wiki_archive`    WHERE ar_comment_id = '0' AND (1=1)  ORDER BY ar_id LIMIT 100
Function: MigrateComments::migrate
Error: 1054 Unknown column 'ar_comment_id' in 'where clause' (localhost)
Backtrace:</nowiki>

#0 /var/lib/mediawiki/includes/libs/rdbms/database/Database.php(1556): Wikimedia\Rdbms\Database->getQueryExceptionAndLog(string, integer, string, string)
#1 /var/lib/mediawiki/includes/libs/rdbms/database/Database.php(1274): Wikimedia\Rdbms\Database->reportQueryError(string, integer, string, string, boolean)
#2 /var/lib/mediawiki/includes/libs/rdbms/database/Database.php(1784): Wikimedia\Rdbms\Database->query(string, string)
#3 /var/lib/mediawiki/maintenance/migrateComments.php(159): Wikimedia\Rdbms\Database->select(string, array, array, string, array)
#4 /var/lib/mediawiki/maintenance/migrateComments.php(53): MigrateComments->migrate(string, array, string)
#5 /var/lib/mediawiki/maintenance/Maintenance.php(1719): MigrateComments->doDBUpdates()
#6 /var/lib/mediawiki/includes/installer/DatabaseUpdater.php(1279): LoggedUpdateMaintenance->execute()
#7 /var/lib/mediawiki/includes/installer/DatabaseUpdater.php(489): DatabaseUpdater->migrateComments()
#8 /var/lib/mediawiki/includes/installer/DatabaseUpdater.php(453): DatabaseUpdater->runUpdates(array, boolean)
#9 /var/lib/mediawiki/maintenance/update.php(203): DatabaseUpdater->doUpdates(array)
#10 /var/lib/mediawiki/maintenance/doMaintenance.php(96): UpdateMediaWiki->execute()
#11 /var/lib/mediawiki/maintenance/update.php(266): require_once(string)
#12 {main}
Beardedfool (talk) 11:31, 10 July 2019 (UTC)
This might be a bug.. I filed https://phabricator.wikimedia.org/T227662 to which you can subscribe.
Do you have any migrate settings specified in your LocalSettings.php ?
And is this mysql/mariadb, or something else ? —TheDJ (Not WMF) (talkcontribs) 13:23, 10 July 2019 (UTC)
Thanks for filling that.
10.1.38-MariaDB-0ubuntu0.18.10.2 Ubuntu 18.10
10.1.40-MariaDB-0ubuntu0.18.04.1 Ubuntu 18.04
Can you talk me through the migrate settings part? At the extent of my knowledge here 81.97.98.8 (talk) 16:55, 10 July 2019 (UTC)
Similar problem with 1.32.x to 1.33 upgrade of migrateComments script, except on column 'pt_reason_id'. Checked MySQL schema and column does not exist in database. DB is MySQL Community 8.0.16. No settings in LocalSettings that seem to be migration related.
stacktrace
Beginning migration of protected_titles.pt_reason to protected_titles.pt_reason_id
[fc9354f975c12aef4fe5b9f2] [no req]   Wikimedia\Rdbms\DBQueryError from line 1587 of ...\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  pt_namespace,pt_title,pt_reason  FROM `protected_titles`    WHERE pt_reason_id = '0' AND (1=1)  ORDER BY pt_namespace,pt_title LIMIT 100
Function: MigrateComments::migrate
Error: 1054 Unknown column 'pt_reason_id' in 'where clause' (localhost)
Backtrace:
#0 ...\includes\libs\rdbms\database\Database.php(1556): Wikimedia\Rdbms\Database->getQueryExceptionAndLog(string, integer, string, string)
#1 ...\includes\libs\rdbms\database\Database.php(1274): Wikimedia\Rdbms\Database->reportQueryError(string, integer, string, string, boolean)
#2 ...\includes\libs\rdbms\database\Database.php(1784): Wikimedia\Rdbms\Database->query(string, string)
#3 ...\maintenance\migrateComments.php(159): Wikimedia\Rdbms\Database->select(string, array, array, string, array)
#4 ...\maintenance\migrateComments.php(61): MigrateComments->migrate(string, array, string)
#5 ...\maintenance\Maintenance.php(1719): MigrateComments->doDBUpdates()
#6 ...\includes\installer\DatabaseUpdater.php(1279): LoggedUpdateMaintenance->execute()
#7 ...\includes\installer\DatabaseUpdater.php(489): DatabaseUpdater->migrateComments()
#8 ...\includes\installer\DatabaseUpdater.php(453): DatabaseUpdater->runUpdates(array, boolean)
#9 ...\maintenance\update.php(203): DatabaseUpdater->doUpdates(array)
#10 ...\maintenance\doMaintenance.php(96): UpdateMediaWiki->execute()
#11 ...\maintenance\update.php(266): require_once(string)
#12 {main}
Iowajason (talk) 15:13, 10 July 2019 (UTC)
So this is reporting errors on database columns that were introduced in 1.30. Have both of you ran pre-1.30 versions at some point in time ? —TheDJ (Not WMF) (talkcontribs) 20:00, 10 July 2019 (UTC)
My Mediawiki install definitely predates 1.30. Clearly recall 1.22 to 1.23 upgrade challenges and think might have been 1.08 or so for initial install. Iowajason (talk) 03:36, 11 July 2019 (UTC)
Also, you seem to have a comment table, can you check what the structure of that table is and report back here (or in the ticket). —TheDJ (Not WMF) (talkcontribs) 20:10, 10 July 2019 (UTC)
MySQL DDL reports:
CREATE TABLE `comment` (
  `comment_id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `comment_hash` int(11) NOT NULL,
  `comment_text` blob NOT NULL,
  `comment_data` blob,
  PRIMARY KEY (`comment_id`),
  KEY `comment_hash` (`comment_hash`)
) ENGINE=InnoDB AUTO_INCREMENT=8651 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci Iowajason (talk) 03:37, 11 July 2019 (UTC)
My pre-upgrade (May) backup version also doesn't seem to have for pt_reason_id flavor of issue:
CREATE TABLE `protected_titles` (
  `pt_namespace` int(11) NOT NULL,
  `pt_title` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NOT NULL,
  `pt_user` int(10) unsigned NOT NULL,
  `pt_reason` tinyblob,
  `pt_timestamp` binary(14) NOT NULL,
  `pt_expiry` varbinary(14) NOT NULL DEFAULT '',
  `pt_create_perm` varbinary(60) NOT NULL,
  PRIMARY KEY (`pt_namespace`,`pt_title`),
  KEY `pt_timestamp` (`pt_timestamp`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci; Iowajason (talk) 04:02, 11 July 2019 (UTC)
I have the exact same problem! I started out using 1.29 (followed by 1.30) and just updated to 1.32. Everything seemed to be working and update.php worked great. I then tried updating to 1.33 and ran into the same problem... "Error: 1054 Unknown column 'ar_comment_id' in 'where clause' (localhost)". I'm dumbfounded. I did have the Comments extension at one time but haven't used it in years. Not sure how to get table structure. Is this what you mean? Do I need to resort back to 1.32? Is it because the Comments extension hasn't been updated in years because I disabled it? I am SO glad it isn't just me having this problem!
mysql> DESCRIBE (or EXPLAIN) comment;
+--------------+---------------------+------+-----+---------+----------------+
| Field        | Type                | Null | Key | Default | Extra          |
+--------------+---------------------+------+-----+---------+----------------+
| comment_id   | bigint(20) unsigned | NO   | PRI | NULL    | auto_increment |
| comment_hash | int (11)            | NO   | MUL | NULL    |                |
| comment_text | blob                | NO   |     | NULL    |                |
| comment_data | blob                | YES  |     | NULL    |                |
+--------------+---------------------+------+-----+---------+----------------+
Bttfvgo (talk) 21:42, 10 July 2019 (UTC)
I also have a table "Comments", rather than "comment", but I'm sure the error refers to the latter.
When I use "describe archive;" I get all of the "ar_" fields (ar_comment is one of them) but the only names ending in "_id" are "ar_id", "ar_rev_id", "ar_text_id", "ar_page_id", and "ar_parent_id". No "ar_comment_id". Bttfvgo (talk) 21:50, 10 July 2019 (UTC)
Looking at the page Manual:Archive_table, my archives table looks identical to the MediaWiki versions 1.25 – 1.29 table. So I don't have the column they are wanting to migrate!  :( Can I create the fields myself? Bttfvgo (talk) 22:38, 10 July 2019 (UTC)
Anyone of you have a backup to check if you had those _id columns before upgrading ?
The weird thing is that those *_id's should have been added at the same time as the comment table was added (and that comment table describe of Bbttfvgo does look correct). Also weird is that some of you have different missing fields than the others..
So either something went wrong in originally adding them during 1.30 or they later got dropped, or there is an error in the migration script or the 1.33 sql updates.. —TheDJ (Not WMF) (talkcontribs) 22:52, 10 July 2019 (UTC)
My Backup from May of this year has (seemingly identical) schema of:
CREATE TABLE `comment` (
  `comment_id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `comment_hash` int(11) NOT NULL,
  `comment_text` blob NOT NULL,
  `comment_data` blob,
  PRIMARY KEY (`comment_id`),
  KEY `comment_hash` (`comment_hash`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */; Iowajason (talk) 03:51, 11 July 2019 (UTC)
I didn't experience problem with that column or several that other reports listed. I did have ar_comment_id, ipb_reason_id, fa_deleted_reason_id, and log_comment_id in my May backup. My Wiki just missing the protected titles ID column. Didn't lose other columns due to 1.33 update, just page display seems to now depend on some of those columns. Iowajason (talk) 04:24, 11 July 2019 (UTC)
Okay I went through my DB backup from MW 1.30 (dated 8-17-2018) and the archives table is identical to the one I have now. Well with one exception. The field named "ar_text" was in the 1.30 backup but now no longer exists. Bttfvgo (talk) 23:28, 10 July 2019 (UTC)
Can we just recreate the missing table fields? Should I switch back to an older version and try the migrateComments.php command?
I went back through a DB backup from MW 1.29 (dated 5-17-2017) and the archive table is there (with the same 19 fields) but the comment table is not. Bttfvgo (talk) 23:45, 10 July 2019 (UTC)
Okay, so I decided to:
mysql> ALTER TABLE archive
    -> ADD COLUMN ar_comment_id INT NOT NULL;
and ran the upgrade script again. This time it actually gave me a different error:
Error: 1054 Unknown column 'ipb_reason_id' in 'where clause' (localhost)
So if I can create all of the columns it claims it is missing, do you think it might actually go through? I'll test the theory, missing file by missing file, and let you know what happens! Bttfvgo (talk) 02:14, 11 July 2019 (UTC)
Okay so I did:
mysql> ALTER TABLE ipblocks
    -> ADD COLUMN ipb_reason_id BIGINT NOT NULL;
and ran the upgrade script and it passed this stage (updated 1039 row(s) with 7 new comment(s)). The next step, 'img_description_id' went through with no problem. (updated 2893 row(s) with 6 new comment(s)). After this I get the error:
Error: 1054 Unknown column 'oi_description_id' in 'where clause' (localhost)
. I'll add this and let you know how it goes! Bttfvgo (talk) 02:25, 11 July 2019 (UTC)
mysql> ALTER TABLE oldimage
    -> ADD COLUMN oi_description_id BIGINT NOT NULL;
and that worked too (updated 121 row(s) with 6 new comment(s)). Next error is 'fa_deleted_reason_id'. Will report back soon. Bttfvgo (talk) 02:28, 11 July 2019 (UTC)
fa_deleted_reason_id
mysql> ALTER TABLE filearchive
    -> ADD COLUMN fa_deleted_reason_id BIGINT NOT NULL;
led to
fa_description_id
mysql> ALTER TABLE filearchive
    -> ADD COLUMN fa_description_id BIGINT NOT NULL;
which led to
rc_comment_id
mysql> ALTER TABLE recentchanges
    -> ADD COLUMN rc_comment_id BIGINT NOT NULL;
which led to
log_comment_id
mysql> ALTER TABLE logging
    -> ADD COLUMN log_comment_id BIGINT NOT NULL;
which led to
pt_reason_id
mysql> ALTER TABLE protected_titles
    -> ADD COLUMN pt_reason_id BIGINT NOT NULL;
My wiki's pretty big so the last two took forever to update but IT WORKS NOW! YEA!!! Hopefully these findings will help many more users, including the two whose thread I inadvertantly hijacked. Thanks again for a superb and superior product. Mediawiki for life! Bttfvgo (talk) 03:17, 11 July 2019 (UTC)
Thank you very much for this post. But in my case (updating from 1.18) there were even more columns missing. So the total script is this:
ALTER TABLE archive ADD COLUMN ar_comment_id INT NOT NULL;
ALTER TABLE ipblocks ADD COLUMN ipb_reason_id BIGINT NOT NULL;
ALTER TABLE oldimage ADD COLUMN oi_description_id BIGINT NOT NULL;
ALTER TABLE filearchive ADD COLUMN fa_deleted_reason_id BIGINT NOT NULL;
ALTER TABLE filearchive ADD COLUMN fa_description_id BIGINT NOT NULL;
ALTER TABLE recentchanges ADD COLUMN rc_comment_id BIGINT NOT NULL;
ALTER TABLE logging ADD COLUMN log_comment_id BIGINT NOT NULL;
ALTER TABLE protected_titles ADD COLUMN pt_reason_id BIGINT NOT NULL;
ALTER TABLE archive ADD COLUMN ar_actor INT NOT NULL;
ALTER TABLE ipblocks ADD COLUMN ipb_by_actor int NOT NULL;
ALTER TABLE image ADD COLUMN img_actor int NOT NULL;
ALTER TABLE oldimage ADD COLUMN oi_actor INT NOT NULL;
ALTER TABLE filearchive ADD COLUMN fa_actor INT NOT NULL;
ALTER TABLE recentchanges ADD COLUMN rc_actor INT NOT NULL;
ALTER TABLE logging ADD COLUMN log_actor INT NOT NULL; Rainer Prem (talk) 15:14, 31 July 2019 (UTC)
Really nice, thank you so much this worked like a charm. 186.210.41.56 (talk) 13:18, 31 October 2019 (UTC)
Oops. Can I change the rpevious post? Rainer Prem (talk) 15:15, 31 July 2019 (UTC)
Zero problem on the hijack as you seem to have an answer, thanks! Though I'll wait to for the more official answer of what to do.
@TheDJ The version before the 1.32.1 was so old it didn't have the comment part in it. Not sure of what version that was I'm afraid
10.1.38-MariaDB-0ubuntu0.18.10.2 Ubuntu 18.10 (version 1.32.1)
+--------------+---------------------+------+-----+---------+----------------+
| Field        | Type                | Null | Key | Default | Extra          |
+--------------+---------------------+------+-----+---------+----------------+
| comment_id   | bigint(20) unsigned | NO   | PRI | NULL    | auto_increment |
| comment_hash | int(11)             | NO   | MUL | NULL    |                |
| comment_text | blob                | NO   |     | NULL    |                |
| comment_data | blob                | YES  |     | NULL    |                |
+--------------+---------------------+------+-----+---------+----------------+
4 rows in set (0.00 sec)
10.1.40-MariaDB-0ubuntu0.18.04.1 Ubuntu 18.04 (version 1.33.0)
MariaDB [wiki]> DESCRIBE wiki_comment;
+--------------+---------------------+------+-----+---------+----------------+
| Field        | Type                | Null | Key | Default | Extra          |
+--------------+---------------------+------+-----+---------+----------------+
| comment_id   | bigint(20) unsigned | NO   | PRI | NULL    | auto_increment |
| comment_hash | int(11)             | NO   | MUL | NULL    |                |
| comment_text | blob                | NO   |     | NULL    |                |
| comment_data | blob                | YES  |     | NULL    |                |
+--------------+---------------------+------+-----+---------+----------------+
4 rows in set (0.00 sec)
Beardedfool (talk) 07:38, 11 July 2019 (UTC)
Right, so it seems all of you had the comment table since 1.30, but not the new *_id columns in the other tables. That likely means no accidental data loss or something scary like that, but it is still very weird, as the table and the new _id fields of the other columns were added in the same SQL change file..
None of you remember running into an error with previous upgrades ? Did any of you run git versions of MediaWiki perhaps ?
The changes that SHOULD have run, but apparently for some of you didn't run completely are:
https://gerrit.wikimedia.org/r/plugins/gitiles/mediawiki/core/+/master/maintenance/archives/patch-comment-table.sql
If you make backups etc and manually try to run these instructions, then maybe you can figure out where things went wrong.. Please don't do things you are not comfortable with. P.S. The /**/ syntax the SQL commands is where the table prefix generally is inserted (often that's just wiki_) —TheDJ (Not WMF) (talkcontribs) 08:38, 11 July 2019 (UTC)
@TheDJ could you look at this report since it sounds similar-ish? MarkAHershberger(talk) 15:37, 11 July 2019 (UTC)
Didn't see any errors before - wouldn't want to bet my life on that but pretty sure. When I get a chance I'll try to setup a new one to test that for you.
I'm not totally comfortable with bits in SQL side but will try those as I have backups and am happy enough dropping the database entirely, Mariadb in necessary. The server isn't doing anything else at present.
Unlikely to be today though, hopefully tomorrow. Thanks for the help!
Couple of questions for my learning please?
So that's mostly copy and enter in SQL command line after sed /*_*/ with wiki_ e.g /*_*/comment becomes wiki_comment
1) What's /*i*/ on lines 12/19?
2) On the CREATE INDEX lines, what does the last part of the line in brackets do e.g. (imgcomment_name) - column name? Beardedfool (talk) 10:08, 11 July 2019 (UTC)
I think this may be collateral damage from the "max key length is 767 bytes" issue with MySQL / UTF support / varchar(255) fields. I hit the max key length problem upgrading to 1.31.
Now trying to upgrade 1.32.1 -> 1.33 I hit this bug. Trying the SQL from patch-comments-table.sql line by line it fails at "CREATE TABLE /*_*/image_comment_temp" because of the max key length problem. It looks like none of the rest of this file was applied.
Are there likely to be other bits of updates that have been missed along the way? Is there some way to validate the whole schema is up to date? Jagatronic (talk) 16:48, 15 July 2019 (UTC)
Having fixed my max length problem and applied everything in patch-comments-table.sql the update progressed until I hit Project:Support desk/Flow/2019/07#h-Upgrade_1.32.1_to_1.33_passes_->_true:_1146_Table_'wiki_revision_actor-2019-07-11T12:50:00.000Z - this is where I first hit the max key length bug a couple of upgrades ago. It turns out my database doesn't have the changes in maintenance/archive/patch-actor-table.sql either (except for the first table: actor).

Jagatronic (talk) 17:21, 15 July 2019 (UTC)
Reran "patch-comment-table.sql" using MySQL Workbench and received SQL syntax error (recall I got further than others with 1.31 update and protected titles the only issue I'm trying to resolve).
SQL:
INSERT OR IGNORE INTO /*_*/protected_titles_tmp (  pt_namespace, pt_title, pt_user, pt_reason, pt_timestamp, pt_expiry, pt_create_perm)   SELECT  pt_namespace, pt_title, pt_user, pt_reason, pt_timestamp, pt_expiry, pt_create_perm   FROM /*_*/protected_titles
ErrirL
Error Code: 1064. You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'OR IGNORE INTO /*_*/protected_titles_tmp (  pt_namespace, pt_title, pt_user, pt_' at line 1 0.079 sec
MySQL didn't like the "OR" command, said "expecting identifier."
This SQL worked (note zero rows since protection not used on my site):
INSERT INTO protected_titles_tmp (
pt_namespace, pt_title, pt_user, pt_reason, pt_timestamp, pt_expiry, pt_create_perm)
  SELECT
pt_namespace, pt_title, pt_user, pt_reason, pt_timestamp, pt_expiry, pt_create_perm
  FROM protected_titles;
Ran rest of file:
DROP TABLE /*_*/protected_titles;
ALTER TABLE /*_*/protected_titles_tmp RENAME TO /*_*/protected_titles;
CREATE UNIQUE INDEX /*i*/pt_namespace_title ON /*_*/protected_titles (pt_namespace,pt_title);
CREATE INDEX /*i*/pt_timestamp ON /*_*/protected_titles (pt_timestamp);
COMMIT;
Then encountered the actor table migration problem mentioned previously.

Iowajason (talk) 00:53, 22 July 2019 (UTC)
@Iowajason You ran the sqlite version instead of the mysql version —TheDJ (Not WMF) (talkcontribs) 08:30, 22 July 2019 (UTC)
Has everyone else got this sorted now. Tried running the patch-comment-table.sql and all seemed to work OK but still get the below
I can't work out from the phabricator link whether this is being dealt with in an update or my next steps
Migrating actors to the 'actor' table, printing progress markers. For large
databases, you may want to hit Ctrl-C and do this manually with
maintenance/migrateActors.php.
Creating actor entries for all registered users
... 1 - 101
... 102 - 202
... 203 - 236
Completed actor creation, added 0 new actor(s)
Beginning migration of revision.rev_user and revision.rev_user_text to revision_actor_temp.revactor_actor
Completed migration, updated 0 row(s) with 0 new actor(s), 0 error(s)
Beginning migration of archive.ar_user and archive.ar_user_text to archive.ar_actor
An error occurred:
A database query error has occurred. Did you forget to run your application's database schema updater after upgrading?
Query: SELECT  ar_id,ar_user,ar_user_text,CASE WHEN ar_user = 0 OR ar_user IS NULL THEN (SELECT  actor_id  FROM `wiki_actor`    WHERE (ar_user_text = actor_name)  ) ELSE (SELECT  actor_id  FROM `wiki_actor`    WHERE (ar_user = actor_user)  ) END AS `actor_id`  FROM `wiki_archive`    WHERE ar_actor = '0' AND (1=1)  ORDER BY ar_id LIMIT 100  
Function: MigrateActors::migrate
Error: 1054 Unknown column 'ar_actor' in 'where clause' (localhost) Beardedfool (talk) 17:39, 12 September 2019 (UTC)

Template:Infobox The time allocated for running scripts has expired.

I have been trying to fix this issue for the better part of an error, Can't figure out what is erroring out. Says that there is no other info. Just timed out.

MediaWiki1.32.2

PHP7.1.28 (litespeed)

MySQL5.6.43-cll-lve

ICU57.1

Lua5.1.5

ParserFunctions 1.6.0 (15fe1aa) 04:09, 20 December 2018
Scribunto (0d6a8f6) 08:56, 15 October 2018
TemplateStyles 1.0 (0f75a12) 11:15, 17 May 2019 GPL-2.0-or-later
2A01:CB1D:83A7:7200:C4:6D13:C05E:7222 (talk) 14:09, 10 July 2019 (UTC)
Might help to increase the CPU time limit. See Extension:Scribunto#LuaStandalone. AhmadF.Cheema (talk) 14:21, 10 July 2019 (UTC)

Cannot access the database:

I am trying to create new wikis , I am using mediawiki 1.33

. I have Mysql , ubuntu 18 and Fedora 29, Python 7.36 , apache 2.4.39.

On both systems when I try to access the database I receive the message

-Cannot access the database: :real_connect(): (HY000/2002): No such file or directory.


I have used both localhost and 127.0.0.1 .. This has been going on for a few months but it has

finally become important ;)


This worked once when I created a blank database, but then I created new blank database

and tried to create a new wiki and it failed

Thank you , it is probably something really simple I am missing

Bill Wjadler123 (talk) 16:55, 10 July 2019 (UTC)

Could you tell us the actual steps that you try? Could you confirm that MySQL is running and that you can connect to it from the command line? MarkAHershberger(talk) 18:43, 12 July 2019 (UTC)
I can access the database from the command line.
I untarred the 1.33.tar file in DocumentRoot - clicked on complete the installation
I filled in the form . I used the user/ password from the command line -
I tried both creating a blank database from the command and using that and using a new database
I tried localhost and 127.0.0.1
I have numerous mediawiki wikis running, but the new operating systems and mediawiki versions
do not seem to like eachother. I am certain I missed something in the instructions, but what?
Thank you

Wjadler123 (talk) 22:22, 12 July 2019 (UTC)

timestamp problem

Hi all

after update from 1.28 to 1.32:

link of 1.32  :http://wikijoo.ir/32

link of 1.28:http://wikijoo.ir

1.32.0
PHP 7.0.33-0ubuntu0.16.04.5 (apache2handler)
MySQL 5.7.25-0ubuntu0.16.04.2
ICU 55.1
Lua 5.1.5

MediaWiki internal error.

Original exception: Wikimedia\Assert\ParameterAssertionException from line 63 of /var/www/html/32/vendor/wikimedia/assert/src/Assert.php: Bad value for parameter $row->rev_timestamp: must be a valid timestamp

Backtrace:

#0 /var/www/html/32/includes/Revision/RevisionStoreRecord.php(73): Wikimedia\Assert\Assert::parameter(boolean, string, string)

#1 /var/www/html/32/includes/Revision/RevisionStore.php(1794): MediaWiki\Revision\RevisionStoreRecord->__construct(Title, User, CommentStoreComment, stdClass, MediaWiki\Revision\RevisionSlots, boolean)

#2 /var/www/html/32/includes/Revision/RevisionStore.php(2757): MediaWiki\Revision\RevisionStore->newRevisionFromRow(stdClass, integer, Title)

#3 /var/www/html/32/includes/Revision.php(1308): MediaWiki\Revision\RevisionStore->getKnownCurrentRevision(Title, integer)

#4 /var/www/html/32/includes/page/WikiPage.php(744): Revision::newKnownCurrent(Wikimedia\Rdbms\DatabaseMysqli, Title, integer)

#5 /var/www/html/32/includes/page/WikiPage.php(766): WikiPage->loadLastEdit()

#6 /var/www/html/32/includes/page/WikiPage.php(638): WikiPage->getRevision()

#7 /var/www/html/32/includes/libs/objectcache/WANObjectCache.php(1277): WikiPage->{closure}(boolean, integer, array, NULL)

#8 /var/www/html/32/includes/libs/objectcache/WANObjectCache.php(1150): WANObjectCache->doGetWithSetCallback(string, integer, Closure, array)

#9 /var/www/html/32/includes/page/WikiPage.php(647): WANObjectCache->getWithSetCallback(string, integer, Closure)

#10 /var/www/html/32/includes/page/WikiPage.php(269): WikiPage->getContentModel()

#11 /var/www/html/32/includes/page/WikiPage.php(256): WikiPage->getContentHandler()

#12 /var/www/html/32/includes/actions/Action.php(98): WikiPage->getActionOverrides()

#13 /var/www/html/32/includes/actions/Action.php(156): Action::factory(string, WikiPage, RequestContext)

#14 /var/www/html/32/includes/MediaWiki.php(155): Action::getActionName(RequestContext)

#15 /var/www/html/32/includes/MediaWiki.php(777): MediaWiki->getAction()

#16 /var/www/html/32/includes/MediaWiki.php(517): MediaWiki->main()

#17 /var/www/html/32/index.php(42): MediaWiki->run()

#18 {main}

OR

when is use rebuildtex.php in putty show this error:

Clearing searchindex table...Done

Rebuilding index fields for 2042149538 pages...

[671f7d80f09b99cf7a1c40b2] [no req]   Wikimedia\Assert\ParameterAssertionExcepti                                                                                        on from line 63 of /var/www/html/32/vendor/wikimedia/assert/src/Assert.php: Bad                                                                                         value for parameter $row->rev_timestamp: must be a valid timestamp


please help me,

best regards Erfansol (talk) 18:10, 10 July 2019 (UTC)

You should check your revisions table in your database for bad timestamps. Maybe there is a row with a null or 0 or a very old timestamp or something —TheDJ (Not WMF) (talkcontribs) 20:59, 10 July 2019 (UTC)
i have same problem,please help 188.121.147.102 (talk) 09:29, 20 July 2019 (UTC)
see Project:Support desk/Flow/2019/07#h-rev_timestamp:_must_be_a_valid-2019-07-23T03:36:00.000Z 212.53.226.26 (talk) 10:21, 8 November 2019 (UTC)

How to hide sysop?

Hello everyone,

I wonder how it would be possible to hide my sysop account form all activites to the public?

So that e.g. it is not possible to bruteforce the exact username?


I tried:

$wgGroupPermissions['sysop']['bot']    = true;

$wgGroupPermissions['sysop']['hideuser'] = true;

$wgGroupPermissions['bureaucrat']['hideuser'] = true;

$wgGroupPermissions['bureaucrat']['bot'] = true;


How ever, when going to "recent changes" it will still show the username next to the changes that have been done with a sysop account. Utini (talk) 19:04, 10 July 2019 (UTC)

You would have to find an appropriate Hook and write some PHP code to modify the query or display of the recent changes page. This isn't really something that fits within the philosophy of MediaWiki, so that sort of functionality is not included out of the box. MarkAHershberger(talk) 22:44, 10 July 2019 (UTC)
Hmm I see. I thought of it like a security enhancement. If the public knows what account names are sysops, then they can aim to compromise those specific accounts.
E.g. usually the 1st registered account (user-id=1)will be an administrator. So I prefer to register a few fake accounts and name e.g. the "user-id=17" as admin.
Or even better.. hide the administrator completely :) Utini (talk) 15:57, 11 July 2019 (UTC)
MediaWiki is not designed with this usecase in mind. At best, if your wiki is entirely private, then nobody can see any of the usernames.
One really hacky method, is enable the 'hideuser' right (This gives you an extra option in Special:Block to hide an account). Keep the account blocked with hideuser enabled whenever you aren't using it, and unblock the user when you need to do something (Depending on config, users can unblock themselves)
Another option is have no admin account. Anytime you need an admin, log into server and run createAndPromote.php from command line [Despite the name, that script can give admin rights to an already existing account instead of creating a new one if the --force option is given] Bawolff (talk) 04:41, 16 July 2019 (UTC)

Elastica\Exception\Connection\HttpException from line 187...\Http.php: Couldn't connect to host, Elasticsearch down?

Product Version
MediaWiki 1.32.0
PHP 7.2.7 (cgi-fcgi)
MySQL 8.0.15
ICU 61.1
CirrusSearch 0.2 (b1fa4bd)06:47, 20 February 2019 GPL-2.0-or-later
Elastica 1.3.0.0 (9fcf88c)02:09, 11 October 2018 GPL-2.0-or-later

I tried to run the commands in the read me and it just states that elasticsearch is down. I've tried to connect using curl localhost:9200 and all it gives me is "curl: (7) Failed to connect to localhost port 9200: Connection refused". I ran a netstat and didn't see port 9200 I've also rebooted and don't have any firewalls running. Is there a way to start the elasticsearch service with this setup? This is the first time installing CirrusSearch and Elastica. Bruceillest (talk) 22:06, 10 July 2019 (UTC)

Try sudo systemctl start elasticsearch. If that works--if there is no error and curl is giving you results--then systemctl can be used to enable it so it starts at boot. To do that, try sudo systemctl enable elasticsearch.
Let us know of any problems. MarkAHershberger(talk) 22:34, 10 July 2019 (UTC)
Mark, thanks for your response but I forgot to mention I am running all of this in Windows server 2012R2. There is no elasticsearch service installed in Windows its only the Elastica extension folder. Is there a batch file or php file I have to run to start it? Bruceillest (talk) 14:18, 11 July 2019 (UTC)
That does make a difference!
You'll need to install ElasticSearch and make sure it is running. MediaWiki will communicate with it to do the searching. MarkAHershberger(talk) 15:16, 11 July 2019 (UTC)
Awesome I'm making progress but now I'm getting this error.
Elastica\Exception\ResponseException from line 179 of C:\inetpub\wwwroot\CAS\extensions\Elastica\vendor\ruflin\elastica\lib\Elastica\Transport\Http.php: Root mapping definition has unsupported parameters:  [mw_cirrus_metastore : {dynamic=false, properties={mediawiki_version={type=keyword}, mapping_min={type=long}, analysis_maj={type=long}, cirrus_commit={type=keyword}, mapping_maj={type=long}, wiki={type=keyword}, shard_count={type=long}, type={type=keyword}, index_name={type=keyword}, mediawiki_commit={type=keyword}, analysis_min={type=long}, namespace_name={norms=false, analyzer=near_match_asciifolding, type=text, index_options=docs}}}] [reason: Failed to parse mapping [_doc]: Root mapping definition has unsupported parameters:  [mw_cirrus_metastore: {dynamic=false, properties={mediawiki_version={type=keyword}, mapping_min={type=long}, analysis_maj={type=long}, cirrus_commit={type=keyword}, mapping_maj={type=long}, wiki={type=keyword}, shard_count={type=long}, type={type=keyword}, index_name={type=keyword}, mediawiki_commit={type=keyword}, analysis_min={type=long}, namespace_name={norms=false, analyzer=near_match_asciifolding, type=text, index_options=docs}}}]]
I installed Elasticsearch v7.2.0 is this issue due to the version I'm using? Bruceillest (talk) 17:21, 12 July 2019 (UTC)
Yes, you need Elasticsearch 5.5.x or 5.6.x as the CirrusSearch page says. MarkAHershberger(talk) 17:44, 12 July 2019 (UTC)
Yep sorry about that I noticed that late. So I installed elasticsearch and was able to run all the commands apparently well but when I search for a page it won't populate. I added "&action=cirrusDump" on pages that show up and don't show up on search and the ones that show up have text information and the searches that don't show up have no text information. I'm guessing some pages are indexing and others aren't so I ran updateSearchIndexConfig.php --reindexAndRemoveOk --indexIdentifier=now and forceSearchIndex.php and still no dice. I ended up installing elasticsearch 5.6.0.
Also when I ran forceSearchIndex.php --skipLinks --indexOnSkip and forceSearchIndex.php --skipParse commands I didn't get an output which I was wondering if that's normal. Bruceillest (talk) 19:41, 15 July 2019 (UTC)
Does it populate your index even though it isn't printing? MarkAHershberger(talk) 19:43, 15 July 2019 (UTC)
How can I tell if it populates my index?

Bruceillest (talk) 20:58, 15 July 2019 (UTC)
This is the output I get when I run
C:\Windows\system32>curl localhost:9200/_cat/indices?v
health status index                      uuid                    pri rep docs.count docs.deleted store.size pri.store.size
green  open   mw_cirrus_metastore_first  U05k9IpgRTyliejRcCPbcw    1    0          21           18      18.3kb         18.3kb
green  open   caswiki_general_1563218277 fO7-X4mmTAGDn-JY0jleNA   4    0          0            0        648b            648b
green  open   caswiki_content_1563218273 bns-287uS36967cO13eY9g    4    0          9            0    652.2kb        652.2kb
green  open   .tasks                      KX7oUmTUSui9XV5NIfqhlA   1    0          0            0        191b            191b
I have around 244 pages created with a lot of content so I guessing these numbers should be more. Bruceillest (talk) 21:14, 15 July 2019 (UTC)
I really don't know that much about ElasticSearch. When I said "does it populate your index?" I meant, "can you find pages via searching? If so, your index is probably being populated." MarkAHershberger(talk) 17:41, 16 July 2019 (UTC)

Subst: with tplargs

Hi. I am trying to develop a template on Wikisource whose output is presumed to be subst:ed once the parameters passed to it are perfected. I have used safesubst: generously throughout, but only one of my tplargs is actually being fully expanded when the entire temlate is called under subst:. This shows my problem. The upper block of wikitext is the subst:ed output of the second (template call) block, but the tplarg {{{chapter}}} is only fully substituted once - I would expect to see 888 substituted for {{{chapter}}} throughout, but I don't wherever the {{{chapter}}} parameter is enclosed in a <section begin= or <section end= tag. Can anyone help me to achieve this, please? Thanks. [[User:CharlesSpencer|CharlesSpencer]] ([[User talk:CharlesSpencer|talk]]) 08:39, 11 July 2019 (UTC) :Try using the #tag form of &lt;section&gt; instead. e.g. <nowiki></nowiki> Bawolff (talk) 04:34, 16 July 2019 (UTC)

Changed language --> Uploaded Pictures are not called correctly

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


Hi there,
I changed the language of my wiki from German to English and now the links to the pictures are not working.
In German the image links starts with [[Datei:.... while in English obviously it starts with [[File:
Since I have already written a sizeable amount of pages, I am looking for a "quicker fix" than manually changing each link...
Can I access the page content of all pages in order to search and replace?
I found a help desk entry about where wiki stores the page content. It talked about a "table" which I was not able to find on my server....
Any ideas?
Many thanks SebastianKazan (talk) 11:34, 11 July 2019 (UTC)
Definitely use ReplaceText and avoid munging with the SQL tables directly. MarkAHershberger(talk) 15:40, 11 July 2019 (UTC)
Maybe Extension:Replace Text AhmadF.Cheema (talk) 12:39, 11 July 2019 (UTC)
Awesome, that worked like a treat!
Many thanks! SebastianKazan (talk) 06:59, 12 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Upgrade 1.32.1 to 1.33 passes -> true: 1146 Table 'wiki_revision_actor

When upgrading from 1.32.1 to 1.33.0 the upgrade.php scripts failes on the actor migration step:

[b59a22daeb86391045110594] [no req]   Wikimedia\Rdbms\DBQueryError from line 1587 of /var/www/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  rev_id,rev_user,rev_user_text,CASE WHEN rev_user = 0 OR rev_user IS NULL THEN (SELECT  actor_id  FROM `wiki_actor`    WHERE (rev_user_text = actor_name)  ) ELSE (SELECT  actor_id  FROM `wiki_actor`    WHERE (rev_user = actor_user)  ) END AS `actor_id`,rev_timestamp AS `revactor_timestamp`,rev_page AS `revactor_page`  FROM `wiki_revision` LEFT JOIN `wiki_revision_actor_temp` ON ((rev_id=revactor_rev))   WHERE revactor_rev IS NULL  ORDER BY rev_id LIMIT 100

Function: MigrateActors::migrateToTemp

Error: 1146 Table 'wiki.wiki_revision_actor_temp' doesn't exist (localhost)


I can only pass the upgrade now when setting wgActorTableSchemaMigrationStage to the setting SCHEMA_COMPAT_OLD. This basically skips the migration but is there a way to let the migration happen without having this error?

Note: Before the wgActorTableSchemaMigrationStage was not set, so it was respecting default values. Captain007 (talk) 12:50, 11 July 2019 (UTC)

This sounds like a similar situation to what's described at phab:T227662. The comment at phab:T227662#5325853 probably applies here as well. Anomie (talk) 19:39, 11 July 2019 (UTC)
I found the script in 1.32 and after partially executing it the upgrade completed. Thanks for the tip. Captain007 (talk) 21:12, 26 July 2019 (UTC)

Delete account

Please close my account and delete my data. I assume you are able to do this as per the GDPR guidelines, right? Thank you! Zadoro (talk) 15:42, 11 July 2019 (UTC)

This is not the right place to make such a request. None of us have those rights. MarkAHershberger(talk) 17:44, 11 July 2019 (UTC)
Wikimedia wiki's generally do not keep personally identifiable information other than what you have provided and that you can delete yourself in your preferences.
Please see meta:Right_to_vanishTheDJ (Not WMF) (talkcontribs) 22:03, 11 July 2019 (UTC)

How to create / styles.css file?

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


Hello I'm new. All my work is in order (https://wiki.sheki.site/) . I only have 2 problems; One of these is that I can not create some files. For example, Module: Citation / CS1 / styles.css has no content How do I create this? The document contains errors. Written: "Are you sure you want to save?" Then it is written: Error: Lua error at line 1: unexpected symbol near '/'. What do I have to do? Thanks in advance. Tofiq Kərimli (talk) 16:02, 11 July 2019 (UTC)

Why do you want to create Module:Citation/CS1/styles.css? AhmadF.Cheema (talk) 16:57, 11 July 2019 (UTC)
Needed for Template:Citation. I can not create sub template for several other templates. Tofiq Kərimli (talk) 18:34, 11 July 2019 (UTC)
Where do you see the Lua error? MarkAHershberger(talk) 17:46, 11 July 2019 (UTC)
When I click the "Save changes" button, this warning is displayed: "Are you sure you want to save?" Second time this warning is displayed:Error: Lua error at line 1: unexpected symbol near '/'. Tofiq Kərimli (talk) 18:43, 11 July 2019 (UTC)
I assume you're trying to copy something like this page.
A non-existent page in the Modules namespace that ends with .css is identified as a CSS page. The same page without .css is identified as scribunto or lua. On your wiki, both are identified as scribunto.
This is handled by TemplateStyles and integration of TemplateStyles with Scribunto is only available since 1.33.
You can try installing the newer Scribunto and TemplateStyles in your current wiki, but it looks like you really need to upgrade the wiki. MarkAHershberger(talk) 22:31, 11 July 2019 (UTC)
I downloaded "Scribunto REL1-33". Everything remained the same. Now, should I change something here (https://wiki.sheki.site/index.php?title=Module:Citation/CS1/styles.css&action=info) ? Tofiq Kərimli (talk) 08:33, 12 July 2019 (UTC)
About my Wiki:
MediaWiki 1.32.1
PHP 7.0.33 (cgi-fcgi)
MySQL 5.7.26
ICU 4.2.1
Lua 5.1.5
Do you need any further information? Tofiq Kərimli (talk) 18:43, 11 July 2019 (UTC)
Have you installed Extension:TemplateStyles ? a requirement for many modern complex templates copied from English Wikipedia. —TheDJ (Not WMF) (talkcontribs) 22:05, 11 July 2019 (UTC)
I just discovered that extension (see my most recent comment above). Could they install just that extension and designate the Module namespace and have it work? MarkAHershberger(talk) 22:39, 11 July 2019 (UTC)
I downloaded "Scribunto REL1-33". Everything remained the same. I wanted to change the module here:
https://wiki.sheki.site/index.php?title=X%C3%BCsusi:ChangeContentModel/Module:Citation/CS1/s.css . It turned out:
[XShOPbuOMIRDVkC8476ujAAAAAQ] /index.php?title=X%C3%BCsusi:ChangeContentModel/Module:Citation/CS1/s.css Error from line 76 of /home/ipekchi/public_html/wiki/extensions/TemplateStyles/includes/TemplateStylesContent.php: Class 'Wikimedia\CSS\Parser\Parser' not found
Backtrace:
#0 /home/ipekchi/public_html/wiki/extensions/TemplateStyles/includes/TemplateStylesContent.php(131): TemplateStylesContent->sanitize(array)
#1 /home/ipekchi/public_html/wiki/includes/Revision/RenderedRevision.php(242): TemplateStylesContent->getParserOutput(Title, NULL, ParserOptions, boolean)
#2 /home/ipekchi/public_html/wiki/includes/Revision/RenderedRevision.php(211): MediaWiki\Revision\RenderedRevision->getSlotParserOutputUncached(TemplateStylesContent, boolean)
#3 /home/ipekchi/public_html/wiki/includes/Revision/RevisionRenderer.php(175): MediaWiki\Revision\RenderedRevision->getSlotParserOutput(string)
-//-
#23 /home/ipekchi/public_html/wiki/index.php(42): MediaWiki->run()
#24 {main}
I downloaded "TemplateStyles REL1-33". When I try to create Module:Citation/CS1/styles.css , it emerges: [XShLfpbzS52E3RAPefNzSgAAAAA] /index.php?title=Module:Citation/CS1/styles.css&action=submit Error from line 78 of /home/ipekchi/public_html/wiki/extensions/TemplateStyles/includes/TemplateStylesContent.php: Class 'Wikimedia\CSS\Parser\Parser' not found
Backtrace:
#0 /home/ipekchi/public_html/wiki/extensions/TemplateStyles/includes/TemplateStylesContent.php(135): TemplateStylesContent->sanitize(array)
#1 /home/ipekchi/public_html/wiki/includes/Revision/RenderedRevision.php(242): TemplateStylesContent->getParserOutput(Title, NULL, ParserOptions, boolean)
#2 /home/ipekchi/public_html/wiki/includes/Revision/RenderedRevision.php(211): MediaWiki\Revision\RenderedRevision->getSlotParserOutputUncached(TemplateStylesContent, boolean)
-//-
#23 /home/ipekchi/public_html/wiki/index.php(42): MediaWiki->run()
#24 {main} Tofiq Kərimli (talk) 09:10, 12 July 2019 (UTC)
I don't think you can install "Scribunto REL1-33" with MediaWiki v1.32 release. You'll have to upgrade your MediaWiki to v1.33 to make use of Scribunto REL1_33. AhmadF.Cheema (talk) 09:16, 12 July 2019 (UTC)
I also did not believe it could be downloaded, but no problem has happened. http://ipekchi.info/wiki/extensions/Scribunto/ But how do I change MediaWiki to v1.33 ? Tofiq Kərimli (talk) 09:27, 12 July 2019 (UTC)
You will need TemplateStyles in addition to the newer Scribunto.
If you just want to upgrade, you can get the update on the download page. MarkAHershberger(talk) 13:40, 12 July 2019 (UTC)
This is on my Wiki: https://wiki.sheki.site/index.php?title=X%C3%BCsusi:Versiya I downloaded "Scribunto REL1-33".
But then "Sanitized CSS" does not exist here (https://wiki.sheki.site/index.php? title=X%C3%BCsusi:ChangeContentModel/Module:Citation/CS1/s.css) . Instead of "Sanitized CSS", Scribunto is located. Tofiq Kərimli (talk) 14:13, 12 July 2019 (UTC)
I see. Then you should just upgrade to the latest version of MediaWiki. MarkAHershberger(talk) 14:42, 12 July 2019 (UTC)
Ok. Thanks. Tofiq Kərimli (talk) 18:41, 12 July 2019 (UTC)
I did that:
MediaWiki 1.33.0
PHP 7.0.33 (cgi-fcgi)
MySQL 5.7.26
ICU 4.2.1
Lua 5.1.5
Nothing has changed. Everything remains the same. Additionally, the following errors appear on all pages: [XSjUIF7nhIiVEDQYFJvOCAAAAAo] /index.php?title=Ana_S%C9%99hif%C9%99&action=edit Error from line 36 of /home/ipekchi/public_html/wiki/extensions/WikiEditor/includes/WikiEditorHooks.php: Call to undefined method EventLogging::sessionInSample()
Backtrace:
#0 /home/ipekchi/public_html/wiki/extensions/WikiEditor/includes/WikiEditorHooks.php(114): WikiEditorHooks::doEventLogging(string, Article, array)
#1 /home/ipekchi/public_html/wiki/includes/Hooks.php(174): WikiEditorHooks::editPageShowEditFormInitial(EditPage, OutputPage)
#2 /home/ipekchi/public_html/wiki/includes/Hooks.php(202): Hooks::callHook(string, array, array, NULL)
#3 /home/ipekchi/public_html/wiki/includes/EditPage.php(2770): Hooks::run(string, array)
#4 /home/ipekchi/public_html/wiki/includes/EditPage.php(712): EditPage->showEditForm()
#5 /home/ipekchi/public_html/wiki/includes/actions/EditAction.php(60): EditPage->edit()
#6 /home/ipekchi/public_html/wiki/includes/MediaWiki.php(499): EditAction->show()
#7 /home/ipekchi/public_html/wiki/includes/MediaWiki.php(294): MediaWiki->performAction(Article, Title)
#8 /home/ipekchi/public_html/wiki/includes/MediaWiki.php(865): MediaWiki->performRequest()
#9 /home/ipekchi/public_html/wiki/includes/MediaWiki.php(515): MediaWiki->main()
#10 /home/ipekchi/public_html/wiki/index.php(42): MediaWiki->run()
#11 {main} Tofiq Kərimli (talk) 15:13, 12 July 2019 (UTC)
When you upgrade your wiki, you generally need to upgrade all the extensions, as well. Try upgrading WikiEditor and the EventLogging extension. MarkAHershberger(talk) 18:45, 12 July 2019 (UTC)
Ok. For example, what version do I choose? Master? Rel1_33?, wmf/1.33.0-wmf.17, wmf/1.33.0-wmf.18 ? Tofiq Kərimli (talk) 18:54, 12 July 2019 (UTC)
REL1_33 MarkAHershberger(talk) 18:57, 12 July 2019 (UTC)
Thanks. Tofiq Kərimli (talk) 19:17, 12 July 2019 (UTC)
Other errors have been corrected. Only "Home Page" is completely lost.
The Module: Citation / CS1 / styles.css has not been created yet. It shows this error:
[XSkAusGSMffooJ-SDnAP@gAAAAM] /index.php?title=X%C3%BCsusi:ChangeContentModel/ Error from line 78 of /home/ipekchi/public_html/wiki/extensions/TemplateStyles/includes/TemplateStylesContent.php: Class 'Wikimedia\CSS\Parser\Parser' not found
Backtrace:
#0 /home/ipekchi/public_html/wiki/extensions/TemplateStyles/includes/TemplateStylesContent.php(135): TemplateStylesContent->sanitize(array)
#1 /home/ipekchi/public_html/wiki/includes/Revision/RenderedRevision.php(265): TemplateStylesContent->getParserOutput(Title, NULL, ParserOptions, boolean)
#2 /home/ipekchi/public_html/wiki/includes/Revision/RenderedRevision.php(234): MediaWiki\Revision\RenderedRevision->getSlotParserOutputUncached(TemplateStylesContent, boolean)
#3 /home/ipekchi/public_html/wiki/includes/Revision/RevisionRenderer.php(193): MediaWiki\Revision\RenderedRevision->getSlotParserOutput(string)
#4 /home/ipekchi/public_html/wiki/includes/Revision/RevisionRenderer.php(142): MediaWiki\Revision\RevisionRenderer->combineSlotOutput(MediaWiki\Revision\RenderedRevision, array)
-//-
#21 /home/ipekchi/public_html/wiki/includes/MediaWiki.php(865): MediaWiki->performRequest()
#22 /home/ipekchi/public_html/wiki/includes/MediaWiki.php(515): MediaWiki->main()
#23 /home/ipekchi/public_html/wiki/index.php(42): MediaWiki->run()
#24 {main} Tofiq Kərimli (talk) 22:01, 12 July 2019 (UTC)
Interestingly, info on Module:Citation/CS1/style.css shows a "Page content model" of "Sanitized CSS" while info on Module:Citation/CS1/styles.css shows just "CSS".
TemplateStyles only uses "Sanitized CSS" so something is wrong with the content model of the page. MarkAHershberger(talk) 23:06, 12 July 2019 (UTC)
Initially, "Sanitized CSS" does not appear. Then "Sanitized CSS" does not exist here (https://wiki.sheki.site/index.php? title=X%C3%BCsusi:ChangeContentModel/Module:Citation/CS1/s.css) . Instead of "Sanitized CSS", Scribunto is located. After changing to CSS or Scribunto, "Sanitized CSS" appears. But it can not be activated. The above error occurs. What should be done? Tofiq Kərimli (talk) 01:02, 13 July 2019 (UTC)
I don't think you should use the Special:ChangeContentModel page to change the content type. Just let Scribunto and TemplateStyles do their thing. Can you revert your changes? MarkAHershberger(talk) 04:00, 13 July 2019 (UTC)
Unfortunately, I do not know how to get back. But it seems to me that it's the same as before. Both pages have been deleted. Tofiq Kərimli (talk) 08:43, 13 July 2019 (UTC)
I've updated all the extensions. But "Module: Citation / CS1 / styles.css" did not appear. Moreover, "MediaWiki 1.33" works very slowly. does not open "commons.wikimedia" files. Tofiq Kərimli (talk) 17:14, 13 July 2019 (UTC)
Could you re-install with 1.33 so we can see what info on Module:Citation/CS1/styles.css shows?
I'm not sure what you mean by 'does not open "commons.wikimedia" files' but that sounds like a bug that we should find more information about. MarkAHershberger(talk) 17:57, 13 July 2019 (UTC)
True, the problem of "commons.wikimedia" files probably appeared for another reason. Because I have resumed the MediaWiki version 1.33, the problem remains: https://wiki.sheki.site/index.php?title=X%C3%BCsusi:WantedFiles I do not know why, maybe some extensions have changed. For example, because I downloaded "Scribunto REL1_33" instead of "Scribunto REL1_32". I think that if I return them to the previous situation, it will probably be the same as before. Tofiq Kərimli (talk) 18:27, 13 July 2019 (UTC)
It shows that you still have 1.32 extensions installed instead of 1.33 ones. Let me know when/if you get that straightened out. MarkAHershberger(talk) 19:18, 13 July 2019 (UTC)
I understand that nobody knows how to solve the problem. Therefore, there is no answer to my question. Tofiq Kərimli (talk) 10:25, 14 July 2019 (UTC)
I returned everything back. But now the situation is worse. Nothing works. The site does not open. First, did I have to do it: http://wiki.sheki.site/mw-config/index.php ? Tofiq Kərimli (talk) 19:43, 13 July 2019 (UTC)
I resumed version 1-32.1 with "http://wiki.sheki.site/mw-config/". Expansions remain in the "1-33" version. There is no problem. Now there is no problem with "commons.wikimedia". Tofiq Kərimli (talk) 21:09, 13 July 2019 (UTC)
I downloaded "MediaWiki 1.33.0" again.
Məhsul Versiya
MediaWiki 1.33.0
PHP 7.0.33 (cgi-fcgi)
MySQL 5.7.26
ICU 4.2.1
Lua 5.1.5
All the extensions were originally "1.33". I wrote this above. No pages can be edited. When I wanted to edit the pages, but the following errors appeared on all pages:
[XSrnNnnkxR@u@UeB5zGZgQAAAAU] /index.php?title=Dinar&action=edit Error from line 36 of /home/ipekchi/public_html/wiki/extensions/WikiEditor/includes/WikiEditorHooks.php: Call to undefined method EventLogging::sessionInSample()
Backtrace:
#0 /home/ipekchi/public_html/wiki/extensions/WikiEditor/includes/WikiEditorHooks.php(114): WikiEditorHooks::doEventLogging(string, Article, array)
#1 /home/ipekchi/public_html/wiki/includes/Hooks.php(174): WikiEditorHooks::editPageShowEditFormInitial(EditPage, OutputPage)
#2 /home/ipekchi/public_html/wiki/includes/Hooks.php(202): Hooks::callHook(string, array, array, NULL)
#3 /home/ipekchi/public_html/wiki/includes/EditPage.php(2770): Hooks::run(string, array)
#4 /home/ipekchi/public_html/wiki/includes/EditPage.php(712): EditPage->showEditForm()
#5 /home/ipekchi/public_html/wiki/includes/actions/EditAction.php(60): EditPage->edit()
#6 /home/ipekchi/public_html/wiki/includes/MediaWiki.php(499): EditAction->show()
#7 /home/ipekchi/public_html/wiki/includes/MediaWiki.php(294): MediaWiki->performAction(Article, Title)
#8 /home/ipekchi/public_html/wiki/includes/MediaWiki.php(865): MediaWiki->performRequest()
#9 /home/ipekchi/public_html/wiki/includes/MediaWiki.php(515): MediaWiki->main()
#10 /home/ipekchi/public_html/wiki/index.php(42): MediaWiki->run()
#11 {main}
Does not open "commons.wikimedia" files. Should we go back or solve this problem? Tofiq Kərimli (talk) 08:43, 14 July 2019 (UTC)
Usually, your MediaWiki core and extensions have to be correspond to the same release.
Take a look at the error description. It mentions "extensions/WikiEditor" and a call to an undefined method. This usually means that the release versions of your WikiEditor extension and MediaWiki core do not match.
Make sure your Extension:WikiEditor is the right version. AhmadF.Cheema (talk) 10:52, 14 July 2019 (UTC)
I checked, I was convinced that WikiEditor is "REL1_33". Nevertheless, I uploaded it again. nothing changed. All the extensions are 1_33. http://ipekchi.info/wiki/extensions/

Tofiq Kərimli (talk) 11:10, 14 July 2019 (UTC)
Now I'll check it again. I'm paying attention to the fact that when the name "EventLogging" is removed from the "LocalSettings.php" page, the errors disappear. Tofiq Kərimli (talk) 10:57, 14 July 2019 (UTC)
This is the main cause of the problem: EventLogging. I've created a new Viki. The same thing happened again: http://sheki.site/index.php?title=Ana_S%C9%99hif%C9%99&action=edit Tofiq Kərimli (talk) 14:08, 14 July 2019 (UTC)
Your Extension:EventLogging as noted at ipekchi.info/wiki/extensions appears to be for 1.32 instead of 1.33. AhmadF.Cheema (talk) 16:22, 14 July 2019 (UTC)
No, I checked them all, and sometimes I downloaded it several times. I uploaded a new one here ( расширение: EventLogging, - mediawiki-extensions-EventLogging-REL1_33 ) . Look, the history of both of them is the same. Tofiq Kərimli (talk) 16:56, 14 July 2019 (UTC)
Look at the extension.json file for REL1_33 at GitHub and the same file for your two versions EventLogging, and EventLogging32.
They are different. For example, the "requires" section. AhmadF.Cheema (talk) 17:26, 14 July 2019 (UTC)
Interesting? But here is 1-33: http://ipekchi.info/wiki/extensions/mediawiki-extensions-EventLogging-REL1_33/extension.json What, then, should we do? Tofiq Kərimli (talk) 17:40, 14 July 2019 (UTC)
Changed, now shows 1-33: http://ipekchi.info/wiki/extensions/EventLogging/extension.json But mistakes remain in place. Errors continue: https://wiki.sheki.site/index.php?title=Portal:Az%C9%99rbaycan_xalq%C4%B1n%C4%B1n_d%C3%B6vl%C9%99t%C3%A7ilik_tarixind%C9%99_%C5%9E%C9%99ki&action=edit But there is a problem: Does not open "commons.wikimedia" files. What can be the reason for this? Tofiq Kərimli (talk) 18:28, 14 July 2019 (UTC)
I've created a new Wiki.
Məhsul Versiya
MediaWiki 1.33.0
PHP 7.0.33 (cgi-fcgi)
MySQL 5.7.26
ICU 4.2.1
Lua 5.1.5
Extensions are those contained in it. I have just downloaded "Scribunto-REL1_33" and TemplateStyles-REL1_33. But it is not possible to create "Module: Citation / CS1 / styles.css". Here Anomie pointed out the solution to the problem: "You probably forgot to run composer update --no-dev as described at Extension:TemplateStyles#Installation?" But the "composer update" file does not exist here and I do not know what to do? AhmadF.Cheema and MarkAHershberger, I would be very happy if you told me that. Tofiq Kərimli (talk) 13:10, 16 July 2019 (UTC)
Re: composer. There is no "composer update" file. That would be a command you run.
Do you have shell access? If not, fulfilling the dependencies is going to be a problem. MarkAHershberger(talk) 02:18, 17 July 2019 (UTC)
Are you sure you've got the files correct?
Your TemplateStyles-REL1_33 folder has 10 items while the one I downloaded from Special:ExtensionDistributor/TemplateStyles has 16. Similarly your Scribunto-REL1_33 has 13 items, while the one from Special:ExtensionDistributor/Scribunto has 22. AhmadF.Cheema (talk) 15:23, 16 July 2019 (UTC)
No, I think there is no difference. These files (Scribunto: .eslintrc.json; .gitignore; .minus-x.json; .gitreview; .phpcs.xml; .stylelintrc.json and TemplateStyles: .eslintrc.json; .gitignore; .gitreview; .phpcs.xml ) do not appear there, but appear in "ftp"... The cause of the problem is known. Here Anomie pointed out the solution to the problem: "You probably forgot to run composer update --no-dev as described at Extension:TemplateStyles#Installation?" But the "composer update" file does not exist here and I do not know what to do? I would be very happy if you told me that. Tofiq Kərimli (talk) 17:27, 16 July 2019 (UTC)
When I try to create a "Module: Citation / CS1 / styles.css, the following error appears:"
[XS4dotTx@UPJx-C1o@Y-CAAAAA4] /index.php?title=Module:Citation/CS1/styles.css&action=submit Error from line 78 of /home/ipekchi/public_html/sheki.site/extensions/TemplateStyles/includes/TemplateStylesContent.php: Class 'Wikimedia\CSS\Parser\Parser' not found
Backtrace:
#0 /home/ipekchi/public_html/sheki.site/extensions/TemplateStyles/includes/TemplateStylesContent.php(135): TemplateStylesContent->sanitize(array)
#1 /home/ipekchi/public_html/sheki.site/includes/Revision/RenderedRevision.php(265): TemplateStylesContent->getParserOutput(Title, NULL, ParserOptions, boolean)
#2 /home/ipekchi/public_html/sheki.site/includes/Revision/RenderedRevision.php(234): MediaWiki\Revision\RenderedRevision->getSlotParserOutputUncached(TemplateStylesContent, boolean)
--//--
#26 /home/ipekchi/public_html/sheki.site/index.php(42): MediaWiki->run()
#27 {main} Tofiq Kərimli (talk) 19:01, 16 July 2019 (UTC)
We're getting somewhere. At least the right content handler is being used. MarkAHershberger(talk) 02:21, 17 July 2019 (UTC)
You do need to take care of the composer dependencies. The error is because the composer dependency for TemplateStyles isn't fulfilled. Do you have command line access to the server? MarkAHershberger(talk) 02:45, 17 July 2019 (UTC)
Thank you for your attention. I have command line access to the server. I learned a lot in a month. Only I can not learn this: take care of the composer dependencies Tofiq Kərimli (talk) 08:07, 17 July 2019 (UTC)
You need to download composer.phar and then rename composer.local.json-sample to composer.local.json. In compose.local.json, replace extensions/example/composer.json with extensions/TemplateStyles/composer.json and then run this command: php composer.phar update --no-dev. That should install the dependencies you need. Once you've run that command, could you paste the output here so we can help if you run into problems later. MarkAHershberger(talk) 14:24, 17 July 2019 (UTC)
MarkAHershberger, thank you very much. No such clear explanation elsewhere. I easily understood what you wrote. But I did not understand two things:
1. I need to download composer.phar. Where to download; on "extensions / TemplateStyles"? Or inside the root MediaWiki directory?
2. Only one thing I did not understand: "run this command: php composer.phar update --no-dev" . So, do I need to write it in "composer.local.json"? I wrote so:
{
"extra": {
"merge-plugin": {
"include": [
"extensions/TemplateStyles/composer.json"
]
}
},
        "php composer.phar update": "no-dev"
} Tofiq Kərimli (talk) 16:58, 17 July 2019 (UTC)
> I need to download composer.phar. Where to download?
The instructions to download composer.phar are on the linked page above. This is the gecomposer.org/download page. It does not mentione composer.phar directly, but that is the file produced by the command php composer-setup.php.
The commands on the download page are currently:
  1. php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
  2. php -r "if (hash_file('sha384', 'composer-setup.php') === '48e3236262b34d30969dca3c37281b3b4bbe3221bda826ac6a9a62d6444cdb0dcd0615698a5cbe587c3f0fe57a54d8f5') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;"
  3. php composer-setup.php
  4. php -r "unlink('composer-setup.php');"
Note that hash in #2 may change by the time you read this, so you need to copy the commands directly from the getcomposer.org/download page. These commands need to be run using your shell access on the command line.
Run these command to download composer.phar inside the your root MediaWiki directory.
You said you have shell access, so you can run these commands at the command prompt after you log in. MarkAHershberger(talk) 00:01, 18 July 2019 (UTC)
Thank you.
1.Yesterday I downloaded composer.phar to the root MediaWiki directory.
2. Then I renamed composer.local.json-sample to composer.local.json.
3. In compose.local.json, I replaced extensions / example / composer.json with extensions / TemplateStyles / composer.json.
4. ? Then I need to run this command: php composer.phar update --no-dev ? I can not do that. Because I can not understand. What is "--no-dev"? I can not do that. Because I can not understand. What is "--no-dev"? In compose.local.json? So: {
"extra": {
"merge-plugin": {
"include": [
"extensions/TemplateStyles/composer.json"
]
}
},
        "php composer.phar update": "no-dev"
}? Tofiq Kərimli (talk) 11:49, 18 July 2019 (UTC)
When the instruction is to run a command, it doesn't mean that you need to edit some file. You have to run that command through some terminal (like cmd, PuTTY etc.).
For running such commands, you'll first need to connect to your computer through SSH to your website's host server. Your hosting service should have instructions on exactly how to do this.
As a beginner, see How does SSH Work (only up to the second section How Does SSH Work, the rest is mostly unnecessary). AhmadF.Cheema (talk) 12:20, 18 July 2019 (UTC)
AhmadF.Cheema, thank you very much. It will be very difficult for me to do so. Most of all, I did not know anything about it so far. My domain is in "cPanel" host. None of the posts here are on my terminal. I understand that I have to follow this instruction: https://www.hostinger.com/tutorials/vps/transfer-backup-to-vps . Did I understand straight? Tofiq Kərimli (talk) 18:24, 18 July 2019 (UTC)
Why do you think you need to transfer your account to VPS? This has nothing to do with what has been mentioned previously.
Which hosting service and host plan are you using? AhmadF.Cheema (talk) 18:56, 18 July 2019 (UTC)
For cPanel & WHM version 82.
I found 4 links on my terminal. Which of these should I look up?
Use the SSH access one. MarkAHershberger(talk) 21:08, 18 July 2019 (UTC)
MarkAHershberger, this video shows that (0:17) should have the "SSH / Shel Access" button. But I do not have such a button. I downloaded "PuTTY". But, unfortunately, I could not activate it. Maybe if I get another host, will this problem be solved? Tofiq Kərimli (talk) 11:51, 20 July 2019 (UTC)
Make sure that your host provides shell access. You can get a VPS pretty cheaply from Linode (for example) if that helps. MarkAHershberger(talk) 14:53, 20 July 2019 (UTC)
I had such a mistake. It seems that this problem can be solved. Tofiq Kərimli (talk) 21:03, 20 July 2019 (UTC)
Hurrah! Was it a firewall issue?
I'm glad you managed to resolve the issues here even if it did take us all more than a week. MarkAHershberger(talk) 23:04, 20 July 2019 (UTC)
MarkAHershberger,Thanks for the help. I learned something. I read a lot and asked a lot of questions. But, unfortunately, there was no result. This is a very difficult job. I could not do that. Tofiq Kərimli (talk) 10:21, 22 July 2019 (UTC)
I'm sorry to hear that. But are you able to use Putty to access your site? MarkAHershberger(talk) 13:35, 22 July 2019 (UTC)
I could not do that. Posted: PuTTY fatal error There are so many videos that I've looked up, and there is no help. It was very important to me. Unfortunately, all my attempts were unsuccessful. But there is still a way, the last way. One of you can download the Wikibase and Template Style for me. I can give him a password. If anyone agrees, I'll be glad. And I thank him in advance. This is the last way for me. Tofiq Kərimli (talk) 16:51, 22 July 2019 (UTC)
Can't give any guarantees, but can try. You can send me the credentials through email. AhmadF.Cheema (talk) 18:54, 24 July 2019 (UTC)
Thanks. I sent. Tofiq Kərimli (talk) 21:36, 24 July 2019 (UTC)
Tofiq Kərimli (talk) 14:18, 21 July 2019 (UTC)
Within a month, I expect someone to answer my question. But no one answers. But I hope that the answer will be soon. I look forward to this minute. Tofiq Kərimli (talk) 21:57, 16 July 2019 (UTC)
Calm down.
It hasn't even been a day, let alone a month. Those of us who post here do so in our free time. Sometimes other things in life have our attention so we are not able to respond quickly. MarkAHershberger(talk) 02:20, 17 July 2019 (UTC)
Even with the hidden items, the numbers don't match.
This is Scribunto's REL1_33/extension.json file on GitHub (the same one obtained through extension distributor) and this is on your server. Both are obviously different (check the "manifest_version" at the end).
Stop assuming things, there is no "composer update" file. Once more, it doesn't appear that you have the correct version copied on your server. AhmadF.Cheema (talk) 02:35, 17 July 2019 (UTC)
Thank you for your attention. I downloaded: Scribunto-REL1_33-8328acb.tar.gz and TemplateStyles-REL1_33-c76fd84.tar.gz . And I activated them. What should I do next? Thank you in advance of your reply. Tofiq Kərimli (talk) 11:41, 17 July 2019 (UTC)
Just fyi, master has manifest_version 2 and, until a few hours ago, the extension distributor didn't have 1.33 as a stable version. Maybe he has the master version. MarkAHershberger(talk) 02:54, 17 July 2019 (UTC)
Yes, I downloaded the "master" version yesterday. Previously, the version was "REL1_33". Do you think I should download the version of "REL1_33" again? Tofiq Kərimli (talk) 07:57, 17 July 2019 (UTC)
It wouldn't hurt, but may not be necessary. MarkAHershberger(talk) 14:15, 17 July 2019 (UTC)
Just checked, unlike the provided installation instructions, Extension:TemplateStyles v1.33 (fromSpecial:ExtensionDistributor) does require running composer install --no-dev to work.
Does this mean a a bug report should be made? AhmadF.Cheema (talk) 01:56, 26 July 2019 (UTC)
AhmadF.Cheema, thank you very much. But I want to know, do you expect me to answer this question? Or should another person respond? Tofiq Kərimli (talk) 10:32, 26 July 2019 (UTC)
someone else AhmadF.Cheema (talk) 11:46, 26 July 2019 (UTC)
Finally, I was able to create the "Module: Citation / CS1 / styles.css" file. Without the use of PuTTY. How?
1. I added the "Vendor" folder to the TemplateStyles folder.
2. I deleted 4 lines starting with "background: URL (// upload.wikimedia.org/wikipedia/commons/thumb/" on the "Module: Citation / CS1 / styles.css" page. The fourth character in each of them was an error.
I am grateful to everyone, especially, @AhmadF.Cheema for their help. Tofiq Kərimli (talk) 18:05, 28 October 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

MediaWiki CSS in common.css works for Vector but not for MinervaNeue

I have an RTL (right-to-left, Hebrew) MediaWiki 1.32.0 website with Vector as desktop theme and MinervaNeue as mobile theme.

In common.css I have added the following code to prevent <pre> LTR (left-to-right) content from moving to the right edge of the screen as all other content would in this RTL site. I gave this class to generally all <pre> tags in the web site.

.preLTR {
    direction: ltr;
}

The problem is that while <pre> content in Vector does go left, <pre> content in MinervaNeue doesn't (although it seems to be accepted in DOM)[1]:

  • Adding !important, saving and clearing cache doesn't help.

What can be the problem?

original post

Already published with Markdown in StackOverflow. Please help:

https://stackoverflow.com/questions/56999109/mediawiki-css-in-common-css-works-for-vector-but-not-for-minervaneue

182.232.10.171 (talk) 02:16, 12 July 2019 (UTC)
@Amire80 has been super-helpful with RTL and CSS before. Perhaps he can help. MarkAHershberger(talk) 13:58, 12 July 2019 (UTC)
I'm not familiar with the "preLTR" class. Does this come from core MediaWiki or did you create it yourself? How did you apply this class to elements? Do you have a template?
Also, can I see this wiki online somewhere? Amir E. Aharoni {{🌎🌍🌏}} 11:57, 14 July 2019 (UTC)

@Amire80 At this point I prefer not to link to the website from anywhere.

  • The templates are Vector and Minerva
  • I created the class myself
  • I added the class this way:
    <pre class=".preLTR">
    
    Anyway, what seems to have been needed is to the add the above CSS class in:

Mediawiki:mobile.css

After I have added it there, the problem seems no longer to exist. 49.230.98.200 (talk) 20:06, 14 July 2019 (UTC)

If you only use this class to set the direction, then you should simply set it in HTML: <pre dir="ltr"></pre>.
W3C recommends not using CSS "direction: ltr" and using HTML attributes instead. Amir E. Aharoni {{🌎🌍🌏}} 20:35, 14 July 2019 (UTC)

Everyone; sorry, I add a mistake above - it's <pre class="preLTR"> instead the dot-including <pre class=".preLTR">.

@Amire80 thanks for noting this recommendation - with due respect to W3C which I generally go by their recommendations, in this particular (rare) case I make an exception; in case I need to reverse and go by their recommendation I can do that by a category categorizing all pages with that class; I'm hard to believe will be a problem years ahead with this particularly. 49.230.98.200 (talk) 22:29, 14 July 2019 (UTC)

with all due respect* 49.230.98.200 (talk) 22:35, 14 July 2019 (UTC)
@Amire80 I take back what I wrote two passages before:
I had a problem I don't know how to explain were direction:rtl didn't give effect (even if !important was added) but dir="rtl" did;
I wrote something in Hebrew and right afterwards parenthesis with the English translation of the term; direction:rtl caused jumbling of characters while dir=rtl didn't.
I have removed the class preRTL and its calls, and instead use dir="ltr". 182.232.21.133 (talk) 21:44, 28 August 2019 (UTC)

Parsoid running but not listening on port?

Hello,

I am not the strongest at *nix, but I can puzzle most things out. This problem has got me baffled.


This is a Bitnami aws image of MediaWiki.


I am running:

Product Version
MediaWiki 1.32.1
PHP 7.1.28 (fpm-fcgi)
MySQL 5.7.26
ICU 64.2
VisualEditor 0.1.0 (6414119)10:41, 3 June 2019


MediaWiki doesn't have Parsoid on its Special:Version page. When I run:


npm version

{ npm: '3.5.2',

  ares: '1.10.1-DEV',

  http_parser: '2.5.0',

  icu: '55.1',

  modules: '46',

  node: '4.2.6',

  openssl: '1.0.2g',

  uv: '1.8.0',

  v8: '4.5.103.35',

  zlib: '1.2.8' }


This would indicate it's not running, but then I get:


~$ service parsoid status

● parsoid.service - LSB: Web service converting HTML+RDFa to MediaWiki wikitext and back

  Loaded: loaded (/etc/init.d/parsoid; bad; vendor preset: enabled)

  Active: active (running) since Wed 2019-07-10 16:58:54 UTC; 10h ago

    Docs: man:systemd-sysv-generator(8)

  Process: 9519 ExecStop=/etc/init.d/parsoid stop (code=exited, status=0/SUCCESS)

  Process: 9530 ExecStart=/etc/init.d/parsoid start (code=exited, status=0/SUCCESS)

    Tasks: 10

  Memory: 27.8M

      CPU: 3.107s

  CGroup: /system.slice/parsoid.service

          ├─9539 /bin/sh -c /usr/bin/nodejs /usr/lib/parsoid/src/bin/server.js -c /etc/mediawiki/parsoid/config.yaml >> /var/log/par

          └─9541 /usr/bin/nodejs /usr/lib/parsoid/src/bin/server.js -c /etc/mediawiki/parsoid/config.yaml

Jul 10 16:58:49 ip-172-31-36-234 systemd[1]: Stopped LSB: Web service converting HTML+RDFa to MediaWiki wikitext and back.

Jul 10 16:58:49 ip-172-31-36-234 systemd[1]: Starting LSB: Web service converting HTML+RDFa to MediaWiki wikitext and back...

Jul 10 16:58:49 ip-172-31-36-234 parsoid[9530]: Started Parsoid server on port 8142

Jul 10 16:58:54 ip-172-31-36-234 systemd[1]: Started LSB: Web service converting HTML+RDFa to MediaWiki wikitext and back.

Jul 11 02:54:10 ip-172-31-36-234 systemd[1]: Started LSB: Web service converting HTML+RDFa to MediaWiki wikitext and back.


So I know it's running, and allegedly listening on 8142. But when I try to do a curl to that port, the connection is refused. Curl sees mediawiki, so I know it works.


I installed all of these from the instructions here at mediawiki.org.


Where should I go from here?


Thanks!

Michael MichaelSFO (talk) 03:46, 12 July 2019 (UTC)

Check your config.yaml and verify that it is pointing to 8142. It may be listening on another port.
Check what the log in /var/log/parsoid says. MarkAHershberger(talk) 13:54, 12 July 2019 (UTC)
I looked in the config. I have serverPort:8142 un-commented. Still refusing.
tailing the parsoid log gives:
{"name":"parsoid","hostname":"ip-172-31-36-234","pid":9550,"level":60,"moduleName":"../src/lib/index.js","levelPath":"fatal/service-runner/worker","msg":"Unexpected token {","time":"2019-07-10T16:58:50.452Z","v":0}
{"name":"parsoid","hostname":"ip-172-31-36-234","pid":9541,"level":40,"message":"first worker died during startup, continue startup","worker_pid":9550,"exit_code":1,"startup_attempt":1,"levelPath":"warn/service-runner/master","msg":"first worker died during startup, continue startup","time":"2019-07-10T16:58:51.464Z","v":0}
Killed
{"name":"parsoid","hostname":"ip-172-31-36-234","pid":16782,"level":30,"levelPath":"info/service-runner","msg":"master(16782) initializing 1 workers","time":"2019-07-12T23:18:37.374Z","v":0}
{"name":"parsoid","hostname":"ip-172-31-36-234","pid":16791,"level":60,"moduleName":"../src/lib/index.js","levelPath":"fatal/service-runner/worker","msg":"Unexpected token {","time":"2019-07-12T23:18:38.016Z","v":0}
{"name":"parsoid","hostname":"ip-172-31-36-234","pid":16782,"level":40,"message":"first worker died during startup, continue startup","worker_pid":16791,"exit_code":1,"startup_attempt":1,"levelPath":"warn/service-runner/master","msg":"first worker died during startup, continue startup","time":"2019-07-12T23:18:39.026Z","v":0}
Killed
{"name":"parsoid","hostname":"ip-172-31-36-234","pid":16830,"level":30,"levelPath":"info/service-runner","msg":"master(16830) initializing 1 workers","time":"2019-07-12T23:21:02.452Z","v":0}
{"name":"parsoid","hostname":"ip-172-31-36-234","pid":16839,"level":60,"moduleName":"../src/lib/index.js","levelPath":"fatal/service-runner/worker","msg":"Unexpected token {","time":"2019-07-12T23:21:03.004Z","v":0}
{"name":"parsoid","hostname":"ip-172-31-36-234","pid":16830,"level":40,"message":"first worker died during startup, continue startup","worker_pid":16839,"exit_code":1,"startup_attempt":1,"levelPath":"warn/service-runner/master","msg":"first worker died during startup, continue startup","time":"2019-07-12T23:21:04.013Z","v":0}
Thanks!
Michael MichaelSFO (talk) 00:11, 13 July 2019 (UTC)
I don't have enough experience to tell you what is going on, but it looks like the server keeps crashing because of "Unexpected token {".
Maybe there is a { in your config.yaml where there shouldn't be? MarkAHershberger(talk) 04:04, 13 July 2019 (UTC)
I stripped the config.yaml down to the essentials, no free whitespace as mentioned elsewhere. No joy. Also upgraded to node 10.
I will reinstall for one more try and then go on to other projects. It seems very difficult to fix this error from what I've read, and no-one has a definitive fix.
Thanks for helping,
Michael MichaelSFO (talk) 13:56, 15 July 2019 (UTC)
Not very familar with node, but the error message makes it sound as if there is a syntax error in ../src/lib/index.js Bawolff (talk) 04:24, 16 July 2019 (UTC)
Parsoid needs a version of nodejs greater or equal to 4, but you're using 3.5.2. That's not compatible. Ciencia Al Poder (talk) 09:12, 16 July 2019 (UTC)
Where do you see that? I'm using 4.2.6 according to npm. Also just upgraded to node 10. MichaelSFO (talk) 20:49, 17 July 2019 (UTC)
Sorry, I though npm was the version of nodejs Ciencia Al Poder (talk) 21:36, 17 July 2019 (UTC)

Current state of working pdf creators for Wiki 1.3.2.1

Hi,


I am trying to setup a pdf creator for our Wiki (Version 1.3.2.1). I was looking to use the Collections extension with the PDF Writer, because of its user friendliness and because it does not require to put in code in each article (as in DocBookExport). Also because it offers the option to select different articles of the wiki and combine them in one book.


Currently there is an error warning that says that:

Book Creator is undergoing changes

Due to severe issues with our existing system, the Book Creator will no longer support saving a book as a PDF for a short period of time. We are working hard to replace our system and re-enable PDFs within the Book Creator.


Does anybody know, if these issues are going to be resolved in the near future?


Otherwise, would you recommend to downgrade the wiki to a version that still support this pdf option?


I also looked into the ElectronPdfService BUT:

- when checking on Github, it says that it is no longer developped

-the author recommends to use https://github.com/alvarcarto/url-to-pdf-api

-the overall installation process is not clear for me and looks much more complicated that the Collection Extension


I also installed Mpdf and it actually is working, BUT again, I cannot compile a pdf book with it.And I do have write a link in each article individually.


What would you recommend me to look at?




SebastianKazan (talk) 09:34, 12 July 2019 (UTC)

Wikimedia currently uses the Proton service, in combination with Collections extension to generate PDFs. It does not currently use the 'Book' creation feature (combining multiple pages into a single pdf). —TheDJ (Not WMF) (talkcontribs) 09:42, 12 July 2019 (UTC)
Do you know if that feature will be restored? SebastianKazan (talk) 13:22, 12 July 2019 (UTC)

Wiki shows only blank pages

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


Hi, I'm running a MediaWiki for some time now. Without any changes from my side the wiki began to show only a blank white page - everywhere. Now I moved it to a new server and upgraded it to the actual version. Got many errors but was able to solve all... except the blank page. It's driving me mad... I have no idea what to do anymore. Any ideas? Address of the wiki is www.diplompsychopath.de/wiki - as you can see it works for a second and then turns into a white page. 79.224.217.90 (talk) 11:48, 12 July 2019 (UTC)

JavaScript present in your Wiki's MediaWiki:Common.js is apparently causing the problems.
Temporarily disable JavaScript in your browser, and remove the "User:Cacycle" related lines. AhmadF.Cheema (talk) 13:25, 12 July 2019 (UTC)
Thanks! That worked :) 79.224.217.90 (talk) 15:28, 12 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Images display with Broken Image Icons

Hi, I enabled uploads, but whatever image I upload it displays with a broken image icon.

http://robocraftxwiki.com/wiki/index.php?title=Main_Page

Product Version
MediaWiki 1.23.9
PHP 7.0.25 (cgi-fcgi)
MySQL 5.6.41-84.1
Josh RCXJammer (talk) 11:52, 12 July 2019 (UTC)
See Project:Support desk/Flow/2016/01#h-500_Error_on_Uploaded_File-MediaWiki_1.26_internal_error-2016-01-23T20:57:00.000Z.
You should upgrade your MediaWiki, aside from the unsupported version, it's also not compatible with such a comparatively recent PHP version. AhmadF.Cheema (talk) 13:09, 12 July 2019 (UTC)

Page confirmation

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


I have submitted a page and am waiting to hear if it has been accepted, but I haven't heard yet. It doesn't' seem to have been rejected, but I"m not sure. How will I know either way and who can I ask? thanks! Lucy Parham (talk) 13:26, 12 July 2019 (UTC)

Your question appears to be unrelated to this website i.e. MediaWiki. You'll have to ask at the particular website where you submitted your article. In case that website was the English Wikipedia, there is some information on your user page there. AhmadF.Cheema (talk) 13:46, 12 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

The Wiki I'm setting up is using several new namespaces to store different categories of user content. This way I am able to control write and edit access for different users to the different content based namespaces.

The issue I'm having is with linking pages using Visual Editor. When I go to search for a page created under my new namespace, the VisualEditor link box will not display any pages outside of the (Main) namespace.

I had to edit $wgNamespacesToBeSearchedDefault in my LocalSettings.php file to include my new namespaces on the Wiki's main search bar defaults, so I'm wondering if VisualEditor has a separate item that needs edited similarly. 8.36.116.204 (talk) 14:50, 12 July 2019 (UTC)

You need $wgVisualEditorAvailableNamespaces. MarkAHershberger(talk) 17:18, 12 July 2019 (UTC)
I thought this variable assigns the namespaces that VisualEditor is enabled in for the user. I'm looking for the variable that defines what namespaces are available for VisualEditor's link search function to look into.
I've gone ahead and added my namespaces into the $wgVisualEditorAvailableNamespaces variable in my LocalSettings.php file, but my issue is still present. 8.36.116.204 (talk) 17:49, 12 July 2019 (UTC)
Ah, sorry. Maybe $wgNamespacesToBeSearchedDefault is what you want? MarkAHershberger(talk) 18:19, 12 July 2019 (UTC)
$wgNamespacesToBeSearchedDefault is for the main WikiMedia search bar (top right of this site). I do not think VisualEditor uses this variable in its link creation search function.
I'm talking about the box that pops up when you click the link/chain icon when typing out a response on here. This box allows you to search for pages on the Wiki that your new link points to.
My issue is that when want to link to a page in a new namespace, the link creation search box will not recognize anything outside of the (Main) namespace. 8.36.116.204 (talk) 18:43, 12 July 2019 (UTC)
I know, but without diving into the code and finding your answer, I am only going on hunches.
There is no documented configuration for what you want, so I thought it might be using $wgNamespacesToBeSearchedDefault to determine where to look. For instance, MediaWiki.org provides suggestions in the Manual namespace and the Manual namespace is one that is in the namespaces to be searched by default.
If that doesn't work, the next step is to phone a friend or go code spelunking. MarkAHershberger(talk) 18:55, 12 July 2019 (UTC)
Thanks for you help.
PHP and web applications are new to me, so that wouldn't be a trivial thing. 8.36.116.204 (talk) 20:25, 12 July 2019 (UTC)
Try manual:$wgContentNamespaces 82.197.207.202 (talk) 20:58, 12 July 2019 (UTC)
I've updated the wgContentNamespaces variable, and the link search seems to be searching for pages in my user defined namespace. The links are all showing up as red, though, until the page the links are on is saved.
So it seems there is still something a little goofy going on, but the feature is now functional. 8.36.116.204 (talk) 16:49, 16 July 2019 (UTC)
Hello,
I am having the same need but using $wgContentNamespaces [] = NS_MYCUSTOMNAMESPACE; does not work for me.
Do you have any updates around this topic?
Thank you. Carloposo (talk) 16:54, 24 November 2021 (UTC)

Warning: session_write_close() on MW 1.30.2

Hello, I am running MediaWiki on hear

Producto Versión
MediaWiki 1.30.2
PHP 5.6.40
MariaDB 10.1.40

In LocalSetting.php

  • $wgDBTableOptions = 'ENGINE=InnoDB, DEFAULT CHARSET=uft8';
  • $wgDBmysql5 = false;
  • $wgMainCacheType = CACHE_DB;

Immediately that I accede with any user I obtain warning message:

Warning: session_write_close(): Failed to write session data (user). Please verify that the current setting of session.save_path is correct (/tmp) in /xxx/includes/session/SessionManager.php on line 469

Please, if someone can help me with the subject, I'll appreciate it

Thanks, Kike_GL Saludos, Kike_GL (talk) 01:16, 13 July 2019 (UTC)

See $wgSessionCacheType and maybe try setting it to CACHE_DB. MarkAHershberger(talk) 04:09, 13 July 2019 (UTC)
I put in LocalSetting.php:
$wgSessionCacheType = CACHE_DB;
No change, same issues
Thanks, Kike_GL Saludos, Kike_GL (talk) 15:22, 13 July 2019 (UTC)
Could you try updating to 1.33? MarkAHershberger(talk) 18:00, 13 July 2019 (UTC)
I have PHP 5.6 and one aplication in my hosting doesn´t support PHP 7.
But thanks, for the suggestion install MW 1.27.7 and now everything works again.
Producto Versión
MediaWiki 1.27.7
PHP 5.6.40
MariaDB 10.1.40
Solved. Thank you very much for your help. Saludos, Kike_GL (talk) 14:41, 14 July 2019 (UTC)

Fatal error: Uncaught Exception: C:\wamp64\www\wiki/extensions/E/extension.json is not a valid JSON file. in C:\wamp64\www\wiki\includes\registration\ExtensionRegistry.php on line 231

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


I am getting this error in my wiki.
Can anybody tell what is not valid in this extension.json file:
{
    "name": "E",
"version": "2.9.4",
"author": [ "PS","xyz"],
"license-name": "GPL-2.0-or-later",
"type": "parserhook",
"requires": {
"MediaWiki": ">= 1.30.0"
},
"AutoloadClasses": {
"E": "E_body.php"
},
"Hooks": {
"ParserFirstCallInit": "E::onParserInit"
},
"ResourceFileModulePaths": {
"localBasePath": "",
"remoteExtPath": "E"
},
"ResourceModules": {
"ext.E.scripts": {
"scripts": "resources/E.js",
},
"ext.E.styles": {
"styles": "resources/E.css"
}
},
    "manifest_version": 1
}
Falcopragati (talk) 11:26, 13 July 2019 (UTC)
This question is unrelated to MediaWiki. There are many online JSON validation tools out there. Malyacko (talk) 12:45, 13 July 2019 (UTC)
I just added a line in "ResourceModules" and no error occurring now.---
"ResourceModules": {
    "ext.E.scripts": {
"scripts": "resources/E.js",
"dependencies": [ "mediawiki.api" ] <---- this line
},

Falcopragati (talk) 12:18, 13 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Wrong behaviour when a section is edited

When a section is edited, the following wrong behaviours happen:

  • Wrong text is displayed (html or markdown text from mediawiki files)
  • Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 2708295328 bytes) in /usr/share/webapps/mediawiki/includes/editpage/TextboxBuilder.php on line 49
  • 502 Bad Gateway
  • Blank page

This only happen when a section is edited. When the whole page is edited everything works well.

  • MW version 1.32.3
  • nginx 1.16.0 - uwsgi 2.0.18 - php 7.3.7 NikusPokus (talk) 15:19, 13 July 2019 (UTC)
Try increasing the memory for PHP. MarkAHershberger(talk) 18:03, 13 July 2019 (UTC)
Whatever the amount of memory I allow, I still have the problem. It looks like a memory leak. I am looking for a solution to fix the cause not the consequences. NikusPokus (talk) 19:57, 13 July 2019 (UTC)
You did not say that you had already tried increasing the memory.
Next thing to try is some debugging lines:
error_reporting( -1 );
ini_set( 'display_errors', 1 );
$wgDebugDumpSql = true;
And you've given us very little information. Can you point to the wiki so we can see this behavior in action?
If you can't share your wiki, it would be good to know what sort of content is on the wiki and how big the pages are and how big your sections are. MarkAHershberger(talk) 21:43, 13 July 2019 (UTC)
Thanks for your comment.
All the sections have the problem whereas the modification of all the pages works well, so it doesn't seem to be a problem with the size of the content.
Here are the errors I have:
Mediawiki
Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 2710392480 bytes) in /usr/share/webapps/mediawiki/includes/editpage/TextboxBuilder.php on line 49
Nginx
2019/07/24 23:45:32 [error] 3337#3337: *9 upstream prematurely closed connection while reading response header from upstream, request: "GET /index.php?title=Test&action=edit&section=1 HTTP/2.0", upstream: "uwsgi://unix:/run/uwsgi/mediawiki.sock:"
Uwsgi
[pid: 3345|app: -1|req: -1/10151] 192.168.0.1 () {48 vars in 927 bytes} [Thu Jul 25 00:31:56 2019] GET /wiki/Test => generated 7152 bytes in 190 msecs (HTTP/2.0 200) 9 headers in 330 bytes (0 switches on core 0)

!!! uWSGI process 3451 got Segmentation Fault !!!

      • backtrace of 3451 ***
      • end of backtrace ***
DAMN ! worker 1 (pid: 3451) died :( trying respawn ...
Respawned uWSGI worker 1 (new pid: 3517)
MySql
jui 25 00:39:31 odroid mysqld[430]: 2019-07-25 0:39:31 81886 [Warning] Aborted connection 81886 host: 'localhost' (Got an error reading communication packets) NikusPokus (talk) 13:06, 27 July 2019 (UTC)
Can I ask why you're using uwsgi? It looks like that is the core of your problem. Maybe switch to php's fpm? MarkAHershberger(talk) 15:41, 27 July 2019 (UTC)
I switched to php-fpm but I still have the problem:
[error] 13891#13891: *34 recv() failed (104: Connection reset by peer) while reading response header from upstream, request: "GET /index.php?title=Test&action=edit&section=1 HTTP/2.0", upstream: "fastcgi://unix:/run/php-fpm/php-fpm.sock:"
php-fpm[317]: [WARNING] [pool www] child 332 exited on signal 11 (SIGSEGV) after 54261.339575 seconds from start
php-fpm[317]: [NOTICE] [pool www] child 13945 started NikusPokus (talk) 01:45, 28 July 2019 (UTC)
I take it the "54261.339575 seconds" is not the actual time? That would mean it had been running for 15 hours.
And, if it had been running for 15 hours, that sounds pretty good.
But segfaults are not good.
Since this is only happening when a section of the page is being ediited, have you tried using the debug log to see if it happens in the same place every time? MarkAHershberger(talk) 02:38, 28 July 2019 (UTC)
In my opinion, the query which fetch the data from edit section retrieve the wrong data. Sometime the content is too long and cause a "String size overflow".
I don't know where to look to find the source of the problem.
Here is the debug log when the edit section doesn't crash but display the wrong data:
debug log
IP: 192.168.0.1
Start request GET /index.php?title=Mediawiki&action=edit&section=2
HTTP HEADERS:
CONTENT-LENGTH:
USER-AGENT: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0
ACCEPT: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
ACCEPT-LANGUAGE: en-US,en;q=0.5
ACCEPT-ENCODING: gzip, deflate, br
DNT: 1
UPGRADE-INSECURE-REQUESTS: 1
TE: trailers
[caches] cluster: APCBagOStuff, WAN: mediawiki-main-default, stash: db-replicated, message: APCBagOStuff, session: SqlBagOStuff
[caches] LocalisationCache: using store LCStoreCDB
[DBConnection] Wikimedia\Rdbms\LoadBalancer::openConnection: calling initLB() before first connection.
[DBReplication] Cannot use ChronologyProtector with EmptyBagOStuff.
[DBReplication] Wikimedia\Rdbms\LBFactory::getChronologyProtector: using request info {
"IPAddress": "192.168.0.1",
"UserAgent": "Mozilla\/5.0 (X11; Linux x86_64; rv:68.0) Gecko\/20100101 Firefox\/68.0",
"ChronologyProtection": false,
"ChronologyPositionIndex": 0,
"ChronologyClientId": null
}
[DBConnection] Wikimedia\Rdbms\LoadBalancer::openLocalConnection: connected to database 0 at 'localhost'.
[SQLBagOStuff] Connection 15428 will be used for SqlBagOStuff
User::getBlockedStatus: checking...
[DBConnection] Wikimedia\Rdbms\LoadBalancer::openLocalConnection: connected to database 0 at 'localhost'.
Title::getRestrictionTypes: applicable restrictions to Mediawiki are {edit,move}
[ContentHandler] Created handler for wikitext: WikitextContentHandler
EditPage::edit: enter
EditPage::importFormData: Not a posted form.
User: loading options for user 2 from override cache.
User::getBlockedStatus: checking...
Unstubbing $wgParser on call of $wgParser::getSection from EditPage->getContentObject
Parser: using preprocessor: Preprocessor_DOM
Unstubbing $wgLang on call of $wgLang::_unstub from ParserOptions->__construct
[Preprocessor] Loaded preprocessor output from cache (key: bananeatomic:preprocess-xml:42d2e30f89584af6c870c4b00e6dcc00:0)
[MessageCache] MessageCache::load: Loading fr... local cache is empty, got from global cache
[MessageCache] MessageCache::load: Loading en... local cache is empty, got from global cache
Title::getRestrictionTypes: applicable restrictions to Mediawiki are {edit,move}
Title::getRestrictionTypes: applicable restrictions to Mediawiki are {edit,move}
MediaWiki::preOutputCommit: primary transaction round committed
MediaWiki::preOutputCommit: pre-send deferred updates completed
MediaWiki::preOutputCommit: LBFactory shutdown completed
Title::getRestrictionTypes: applicable restrictions to Mediawiki are {edit,move}
User: loading options for user 2 from override cache.
User: loading options for user 2 from override cache.
User: loading options for user 2 from override cache.
[gitinfo] Computed cacheFile=/usr/share/webapps/mediawiki/gitinfo.json for /usr/share/webapps/mediawiki
[gitinfo] Cache incomplete for /usr/share/webapps/mediawiki
NikusPokus (talk) 17:11, 28 July 2019 (UTC)
What do you mean by "wrong data"? Is it just gibberish or the wrong section or what? MarkAHershberger(talk) 17:44, 28 July 2019 (UTC)
Depending on the section I try to edit I have the following data displayed:
bitcoin\:|ftp\:\/\/|ftps\:\/\/|geo\:|git\:\/\/|gopher\:\/\/|http\:\/\/|https\:\/\/|irc\:\/\/|ircs\:\/\/|magnet\:|mailto\:|mms\:\/\/|news\:|nntp\:\/\/|redis\:\/\/|sftp\:\/\/|sip\:|sips\:|sms\:|ssh\:\/\/|svn\:\/\/|tel\:|telnet\:\/\/|urn\:|worldwind\:\/\/|xmpp\:
/(?P<a_newsectionlink>__LIENNOUVELLESECTION__)|(?P<b_newsectionlink>)|(?P<a_nonewsectionlink>__AUCUNLIENNOUVELLESECTION__)|(?P<b_nonewsectionlink>)|(?P<a_hiddencat>__CATCACHEE__)|(?P<b_hiddencat>)|(?P<a_index>)|(?P<a_noindex>__AUCUNINDEX__)|(?P<b_noindex>)|(?P<a_staticredirect>__REDIRECTIONSTATIQUE__)|(?P<b_staticredirect>)/S
<div id="wikiPreview" class="ontop" style="display: none;"><div lang="fr" dir="ltr" class="mw-content-ltr"></div></div><form class="mw-editform" id="editform" name="editform" method="post" action="/index.php?title=UberGallery&amp;action=submit" enctype="multipart/form-data"><input type="hidden" value="ℳ𝒲♥𝓊𝓃𝒾𝒸ℴ𝒹ℯ" name="wpUnicodeCheck"/><div id="antispam-container" style="display: none;"><label for="wpAntispam">Vérification anti-pourriel.
Ne <strong>rien</strong> inscrire ici !</label><input type="text" name="wpAntispam" id="wpAntispam" value="" /></div><input type="hidden" name="editingStatsId" id="editingStatsId" value="501bac7d561b918b10eb23ace56e6aa4" /><input type="hidden" value="4" name="wpSection"/><input type="hidden" value="20190728205632" name="wpStarttime"/><input type="hidden" value="20140112230032" name="wpEdittime"/> NikusPokus (talk) 21:03, 28 July 2019 (UTC)
And, I take it that this information isn't on the page anywhere? MarkAHershberger(talk) 21:55, 28 July 2019 (UTC)
You are right, this information isn't on the page anywhere but it is on some other mediawiki system pages. NikusPokus (talk) 07:49, 1 August 2019 (UTC)
I really don't understand your problem, but the first place I would begin to look now is to see if your system is running out of memory. MarkAHershberger(talk) 18:01, 2 August 2019 (UTC)
If PHP is segfaulting, perhaps there is also data corruption, which is what is causing random strings to be displayed on page that shouldn't be.
I suppose try installing a different version of php and see if it goes away (I guess. Not really sure what else to suggest. Maybe a PHP specific form would be able to help you debug the segfault) Bawolff (talk) 20:31, 3 August 2019 (UTC)
The problem seems fixed with the update 1.33.
Thanks for your help. NikusPokus (talk) 10:09, 4 August 2019 (UTC)
Also, maybe try disabling all extensions to rule out that it is an extension causing the problem. Bawolff (talk) 04:21, 16 July 2019 (UTC)
@Bawolff, thanks for your comment. I commented all the extensions but I still have the problem. NikusPokus (talk) 13:02, 27 July 2019 (UTC)

When creating a mediawiki extension, what role does 'package.json' and gruntfile play ?Are they crucial or the extension can work without them too ?

I have created a parserhook extension, in file extension.json i have added the resource module for jQuery .

It is showing no error, but the jQuery part is not working at all. 103.118.50.4 (talk) 15:46, 13 July 2019 (UTC)

They're mostly used by the CI structure in Gerrit, I believe. You don't need them. MarkAHershberger(talk) 18:01, 13 July 2019 (UTC)

I am trying to make a new Extension, but getting an error at line '$parser->getOutput()->addModules( 'ext.E.scripts' )';

The code is edited,and it is working now.

[f49fe744377fe4fd5f717ceb] /wiki/index.php/Main_Page Error from line 7 of C:\wamp64\www\wiki\extensions\E\E_body.php: Call to a member function addModules() on null

Backtrace:

#0 C:\wamp64\www\wiki\includes\Hooks.php(174): EC::onParserInit(Parser)

#1 C:\wamp64\www\wiki\includes\Hooks.php(202): Hooks::callHook(string, array, array, NULL)

#2 C:\wamp64\www\wiki\includes\parser\Parser.php(369): Hooks::run(string, array)

#3 C:\wamp64\www\wiki\includes\cache\MessageCache.php(1190): Parser->firstCallInit()

#4 C:\wamp64\www\wiki\includes\cache\MessageCache.php(1166): MessageCache->getParser()

#5 C:\wamp64\www\wiki\includes\Message.php(1282): MessageCache->transform(string, boolean, LanguageEn, Title)

#6 C:\wamp64\www\wiki\includes\Message.php(883): Message->transformText(string)

#7 C:\wamp64\www\wiki\includes\Message.php(943): Message->toString(string)

#8 C:\wamp64\www\wiki\includes\OutputPage.php(924): Message->text()

#9 C:\wamp64\www\wiki\includes\OutputPage.php(971): OutputPage->setHTMLTitle(Message)

#10 C:\wamp64\www\wiki\includes\page\Article.php(622): OutputPage->setPageTitle(string)

#11 C:\wamp64\www\wiki\includes\actions\ViewAction.php(68): Article->view()

#12 C:\wamp64\www\wiki\includes\MediaWiki.php(501): ViewAction->show()

#13 C:\wamp64\www\wiki\includes\MediaWiki.php(294): MediaWiki->performAction(Article, Title)

#14 C:\wamp64\www\wiki\includes\MediaWiki.php(860): MediaWiki->performRequest()

#15 C:\wamp64\www\wiki\includes\MediaWiki.php(517): MediaWiki->main()

#16 C:\wamp64\www\wiki\index.php(42): MediaWiki->run()

#17 {main} 103.118.50.4 (talk) 18:40, 13 July 2019 (UTC)

Well, at this point you do not have anything in $parser: "Call to a member function addModules() on null". If you want us to help, you'll need to share your source code. MarkAHershberger(talk) 19:19, 13 July 2019 (UTC)
OK, right now it has only 4 files(I am just learning how to create extensions).The Javascript module is not working.
1.Extension.json--
{
    "name": "E",
	"version": "2.9.4",
	"author": [
		"PS",
		"xyz"
	],
	"license-name": "GPL-2.0-or-later",
	"type": "parserhook",
	"requires": {
		"MediaWiki": ">= 1.30.0"
	},
	"AutoloadClasses": {
		"EC": "E_body.php"
	},
	"Hooks": {
		"ParserFirstCallInit": "EC::onParserInit"
		},
	"ResourceFileModulePaths": {
		"localBasePath": "",
		"remoteExtPath": "E"
	},
	"ResourceModules": {
	    "ext.E.scripts": {
			"scripts": "resources/E.js",
			"dependencies": [ "mediawiki.api" ]
		},
		"ext.E.styles": {
			"styles": "resources/E.css"
		}
	},
    "manifest_version": 1	
}
2.E_body.php-->
<?php
class EC {
	static function onParserInit( Parser $parser ) {
		$parser->setHook( 'E', array( __CLASS__, 'ERender' ) ); 
		$parser->getOutput()->addModules( 'ext.E.scripts' );
		return true;
	}
	static function ERender( $input, array $args, Parser $parser, PPFrame $frame ) {
		$ret='<style>table.wtable { border-style:solid; border-width:1px; border-collapse:collapse;} </style>';
	    $ret .= '<table class="wtable">';
		$ret .= '<tr>';
		$ret .= '<td>Feedback</td>';
		$ret .= '<td><input id="inp001" type="text" /></td>';
		$ret .= '</tr>';
		$ret .= '<tr>';
		$ret .= '<td>upvote</td>';
		$ret .= '<td><input id="chk001" type="radio" name="r1"/></td>';
		$ret .= '</tr>';
		$ret .= '<tr>';
		$ret .= '<td><p font-colour=red>downvote</p></td>';
		$ret .= '<td><input id="chk001" type="radio" name="r1" /></td>';
		$ret .= '</tr>';
		$ret .= '<tr><p>here</p>';
        $ret .= '<td align="center" colspan=2><input id="btn001" type="button" value="Submit"></td>';
        $ret .= '</tr>';
		$ret .= '</table>';
		$ret .= '<input type="submit" value="Vote" onclick="myFunction()">/>';
		return $ret;
	}
}
3.E.js-->
$("#btn001").click(function() {
	$("#inp001").html("Hello <b>world!</b>");
	//inp001.innerHTML("Clicked");
	$('p').html("Hello <b>world!</b>");
	alert("Button clicked.");
});
4.E.css-->
table.wtable {
	border-style:solid; border-width:1px; border-collapse:collapse;
}
@MarkAHershberger 103.118.50.4 (talk) 08:42, 14 July 2019 (UTC)
Will someone look at this please ?
I am trying to learn extension creation but right now I am stuck due to this.
Please see this... 103.118.50.4 (talk) 11:24, 15 July 2019 (UTC)
having similar problem Falcopragati (talk) 11:20, 15 July 2019 (UTC)
The problem is your call
$parser->getOutput()->addModules( 'ext.E.scripts' );
in the ParserFirstCallInit hook. That is called too early to have getOutput() be populated.
Move the call so that it is just inside EC:ERender and you'll get what you want. MarkAHershberger(talk) 16:19, 15 July 2019 (UTC)
Thanks Mark ! It worked.
Actually I took this code from [Manual:Tag extensions/Example], in which a tutorial is given about creating an interacting tag.
But due to this ' $parser->getOutput()->addModules' in the wrong place, it does'nt works, and this is not the only line of code on that page which should be corrected..
Maybe you should take a look, and edit the codes on that page to make them right...
I can edit, but I don't think I am qualified to edit that page. 103.118.50.4 (talk) 18:50, 15 July 2019 (UTC)
The code you linked to is wrong, but for a different reasons. Its calling $wgOut->addModules(). $wgOut is available at the parserFirstCallInit, but it doesn't tie the module to your tag. Instead it would cause the module to be added on every page view where the parser is invoked at least once, which would be incorrect for other reasons.
Anyways, i edited the page Bawolff (talk) 04:20, 16 July 2019 (UTC)
I just saw the page. I saw a warning-->
Warning:The MediaWiki ajax action which the code below uses, is deprecated. New code should register an API module instead
can you/@MarkAHershberger or anyone please elaborate more on this? Or can you please add the required modification to the code so that it can work as intended?? It would be very helpful for me and all the people who are exploring MediWiki and trying to learn Extension development. Thanks 103.118.50.4 (talk) 12:36, 16 July 2019 (UTC)
Have a look at the API documentation. You can create an API module to handle the JS calls. MarkAHershberger(talk) 17:18, 16 July 2019 (UTC)
Thanks Brian 103.118.50.4 (talk) 12:14, 16 July 2019 (UTC)

Edgy spam filter?

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


I recently updated this wiki here to V1.31. Now I'm doing this and that to polish up the visual appearance a little bit. Doing so, I discovered an odd behaviour:

Every page that contains the term spam, actually three pages which are dealing with this topic, are rejected by a dubios spam protection filter. This filter claims, that

The page you wanted to save was blocked by the spam filter. This is probably caused by a link to an external site.

and

The following text was found by the spam filter: Spam

And I have to admit: Yes, the term is used on this pages. But to describe something around the topic spam. As far as I know, this is far away from being spam itself.

Subsequently there is really no way to circle around this blocking. Even as Sysop my hands are tied!

So does anybody know a way to stall this edgy spam filter jumping on a harmless four letter word like spam, in particular one will only explain this term.

Many thanks for an answer in advance! Wgkderdicke (talk) 21:24, 13 July 2019 (UTC)

This functionality is not built into MediaWiki. Try disabling some extensions or talk to your host? MarkAHershberger(talk) 21:30, 13 July 2019 (UTC)
Well, in case of this rejected content the de.json file from the languages/i18n folder provides exactly the shown error messages. There are three messages called spamprotectiontitle, spamprotectiontext and spamprotectionmatch. The content of that messages, in addition with the bad word spam, is displayed instead of saving the article. The en.json file also contains the english pendant of this messages, starting in line 3020 of en.json (MW 1.31.3).
Also this messages are mentioned here: Manual:$wgSpamRegex
But it is not changed in my LocalSettings.php. It comes from DefaultSettigs.php as $wgSpamRegex = [];.
The explanation in above mentioned manual also describes my experience: even a Sysop fails to save if that error occurs. Wgkderdicke (talk) 00:34, 14 July 2019 (UTC)
Bingo. I added $wgSpamRegex = false; to my LocalSettings.php. Now the pages which cotains the term spam can be saved again. In contrast to Manual:$wgSpamRegex, which claims that the default value is false, the MW 1.31.3 DefaultSetting.php gives me an empty array instead. Maybe this causes confusion or some weird fallback solution with some odd regex from elsewhere gets suddenly effective. Wgkderdicke (talk) 00:53, 14 July 2019 (UTC)
could you file a task in phabricotor for this bug? MarkAHershberger(talk) 16:23, 15 July 2019 (UTC)
I managed to do this: https://phabricator.wikimedia.org/T228081
I hope that this is what you mean. It's the very first time that I have tried to file something in phabricator. Wgkderdicke (talk) 17:51, 15 July 2019 (UTC)
yes, thanks. MarkAHershberger(talk) 19:45, 15 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Best way to merge forked wikis

Our wiki is publicly available and editable. However, several times a year, our top contributors go to remote areas without reliable internet access for long periods of time. This is also when they have a lot of free time to edit the wiki if they could access it.

We're considering setting up a raspberry pi as an off-grid LAMP server with MediaWiki. Copying over the database and upload directory with the most up to date version of the site, and letting them take it with them. Once they get back we would merge the forked wikis.

But that's where the problem is. What's the best way to merge the two together? Theoretically some pages would be edited by one group and unedited by the other. But some pages could have edits by both groups, some of which don't conflict while others do. Jer Hughes (talk) 00:31, 14 July 2019 (UTC)

This is currently a project that I'm working on via MABS (also this grant).
If you have interest in it, I'd like to get you involved. MarkAHershberger(talk) 16:42, 15 July 2019 (UTC)

Error while thanking a user for an edit.

I installed Extension:Thanks , but when I tried to thank a user in my wiki for a rivison to an article, this error appeared-->
[ab483df2c97b19cad31449d4] /wiki/index.php/Special:Thanks/140 TypeError from line 1223 of C:\wamp64\www\wiki\extensions\Echo\includes\DiscussionParser.php: Argument 1 passed to EchoDiscussionParser::getEditExcerpt() must be an instance of MediaWiki\Revision\RevisionRecord, instance of Revision given, called in C:\wamp64\www\wiki\extensions\Thanks\includes\ApiCoreThank.php on line 50
Backtrace:
0 C:\wamp64\www\wiki\extensions\Thanks\includes\ApiCoreThank.php(50):
EchoDiscussionParser::getEditExcerpt(Revision, LanguageEn)
1 C:\wamp64\www\wiki\includes\api\ApiMain.php(1570): ApiCoreThank->execute()
2 C:\wamp64\www\wiki\includes\api\ApiMain.php(500): ApiMain->executeAction()
3 C:\wamp64\www\wiki\extensions\Thanks\includes\SpecialThanks.php(166): ApiMain-
>execute()
4 C:\wamp64\www\wiki\includes\htmlform\HTMLForm.php(665): SpecialThanks >onSubmit(array, OOUIHTMLForm)
5 C:\wamp64\www\wiki\includes\htmlform\HTMLForm.php(557): HTMLForm->trySubmit()
6 C:\wamp64\www\wiki\includes\htmlform\HTMLForm.php(572): HTMLForm->tryAuthorizedSubmit()
7 C:\wamp64\www\wiki\includes\specialpage\FormSpecialPage.php(184): HTMLForm->show()
8 C:\wamp64\www\wiki\includes\specialpage\SpecialPage.php(569): FormSpecialPage->execute(string)
9 C:\wamp64\www\wiki\includes\specialpage\SpecialPageFactory.php(568): SpecialPage->run(string)
10 C:\wamp64\www\wiki\includes\MediaWiki.php(288): MediaWiki\Special\SpecialPageFactory->executePath(Title, RequestContext)
11 C:\wamp64\www\wiki\includes\MediaWiki.php(860): MediaWiki->performRequest()
12 C:\wamp64\www\wiki\includes\MediaWiki.php(517): MediaWiki->main()
13 C:\wamp64\www\wiki\index.php(42): MediaWiki->run()
14 {main} 103.118.50.4 (talk) 10:49, 14 July 2019 (UTC)
Which exact MediaWiki version? Which exact Echo version? Which exact Thanks version? Malyacko (talk) 17:02, 14 July 2019 (UTC)
MediaWiki 1.32.2
PHP 7.2.18 (apache2handler)
MySQL 5.7.26
ICU 63.1
Extension:Thanks version-1.2.0 (latest stable version)
Echo version can't be seen at the Special:version page, but it is the one which is used for MediaWiki version 1.32.0 or later. 103.118.50.4 (talk) 17:22, 14 July 2019 (UTC)
If the Echo version doesn't show up on the version page, then it probably isn't being used. Did you make sure it is Loaded in LocalSettings.php? MarkAHershberger(talk) 16:39, 15 July 2019 (UTC)
I checked again, it is loaded in LocalSettings.php.
And I am sure it is working because the users are perfectly getting notifications etc in the wiki without any error.
I checked Echo's extension.json file, in that file version is not mentioned, maybe that is why the extension is listed on my Special:version page but it's version is not showing up in the designated field. 103.118.50.4 (talk) 18:36, 15 July 2019 (UTC)
I tried thanking users in StructuredDiscussions, and it is working perfectly !
BUT when I am thanking users for their contributions to an article(thanking through the article history page) , instead of this Backtrace , an alert box is appearing now, saying :
Thank action failed (error code: internal_api_error_TypeError).
 Please try again.
103.118.50.4 (talk) 10:57, 14 July 2019 (UTC)

I want to add messages to the editing pages

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


Hello, I'm Dave!


I would like to add messages to users when they want to edit a page, as Wikipedia does.


I would be grateful if you help me with it!


Thanks, Dave. Dave Spirit (talk) 18:28, 14 July 2019 (UTC)

See Manual:Interface/Edit notice and Wikipedia:Editnotice. AhmadF.Cheema (talk) 20:13, 14 July 2019 (UTC)
Thank you! It was what I was looking for Dave Spirit (talk) 03:04, 17 July 2019 (UTC)
You might also be interested in Extension:NewUserMessage (not used by en wikipedia) Bawolff (talk) 04:00, 16 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Change from 'sqlite' to 'mysql'

Is it possible to change a wiki database from 'sqlite' to 'mysql' ? 2610S (talk) 22:31, 14 July 2019 (UTC)

Probably not the easiest thing to do, but there's no reason why it wouldn't work to just take the sqlite db, select all the info in it, and insert it into a mysql db. The schemas are mildly different (mostly in terms of different "types" supported by different dbs) but still really close, so you would probably want to setup up a mysql db, and then do each table separately to ensure that everything gets copied over correctly. Bawolff (talk) 03:59, 16 July 2019 (UTC)

Disable the Edit Menu's Header Mouseover/Hover "Feature"

I use the Vector skin and I recently updated my wiki to the latest version from a couple versions back. I'm not sure when it started, but now when I'm on any editing page, a "Level" menu appears if my cursor goes over the heading drop down menu, which happens often after I press the edit button and bring the cursor into the textarea. This is extremely frustrating, especially because where I want to put my cursor is always under where the menu is at. I find myself

Is there a way to disable the mouse over feature so the user has to click on the drop down menu to access this little used menu item? Either on a user level setting or a site wide setting? I'm tempted to set a css rule to .group.group-heading{display:none} but I'd rather make this menu item require a click to open instead of fully hiding. Jer Hughes (talk) 00:40, 15 July 2019 (UTC)

I'd like to comment all Sidebar menu links (actually, not all of them besides one).

The rationale is not to delete them (even if I delete them, generally I could always restore earlier version from "View history" but let's say I just want to comment them instead).

Is it possible in version 1.32.0 without installing any extension? 49.230.98.200 (talk) 04:39, 15 July 2019 (UTC)

You can comment them out using <!-- ** menu link --> MarkAHershberger(talk) 16:35, 15 July 2019 (UTC)
Thanks 49.230.76.81 (talk) 22:17, 15 July 2019 (UTC)

API readapidenied error

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


My wiki is publicly readable, and can be edited if the user creates an account. However, I'm trying to use a script that accesses the API file to read content and its getting an readapidenied error "You need read permission to use this module."

The script currently does not support handling credentials. Is there some permission I can change to allow anonymous read permissions for the API? Jer Hughes (talk) 08:52, 15 July 2019 (UTC)

Turns out I do have some read blocking permissions. If I disable them then the script works fine.
$wgGroupPermissions['*']['read'] = false;
$wgWhitelistReadRegexp = ["/^(?!User:).+$/"]; Jer Hughes (talk) 08:56, 15 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Fehler beim Laden der Daten vom Server: apierror-visualeditor-docserver-http: HTTP 500.

Hi All,


im currently working on a problem where my colleagues who created this mediawiki cant work with Visualeditor anymore.

the problem is that mediawikiurl/dmr/php.api isnt getting any tokens forwarded anymore. if i curl from localhost to localhost/dmr/php.api i can access the php.api. If i curl to http://FQDN/dmr/php.api it says "authorization required". This error appeared just out of nowhere. I already tried multiple suggestons i found on the internet, but none of them helped. (ports are open, forwarding is enabled, config files should be fine)

Did someone have the same issue or can someone help me with this one?

Help greatly appreciated. 213.61.249.36 (talk) 08:58, 15 July 2019 (UTC)

I assume you mean api.php, not php.api
That said, it is understandable that localhost would not require authentication but the FQDN does. This is probably handled at the web server level, though, not in MediaWiki. MarkAHershberger(talk) 16:31, 15 July 2019 (UTC)
ah my bad of course i mean api.php. Hmm thanks for the tipp ill take a look into it. 213.61.249.36 (talk) 08:05, 17 July 2019 (UTC)

Change Image Rendering Size when Printable=Yes

I am using the syntax "File: filename.png|728px" to embed Images into my Wiki. I use 728px cause it sits better next to the text in my Wiki. I'm also using Mpdf extension to print out the whole Wiki Page into a pdf. The problem is the syntax creates an extra link of the source image with a compressed version of the Image with the resolution of width="728" height="410". When I take the output with Mpdf, the quality gets super low because of the compressed image that is created.

Question is, is there a way to bypass this Srcset link with the 728px which is created when Printable=Yes and use directly the picture with the original resolution instead?

I am super stuck with this, and I can't find any solution for it. Help is highly appreciated.


OOZ.MOO (talk) 09:01, 15 July 2019 (UTC)

It sounds like you want the PDF rendering to use a higher resolution than than web rendering, right? MarkAHershberger(talk) 16:29, 15 July 2019 (UTC)
Hey Mark, thanks for your feedback. Yes exactly. I want to somehow keep the 728px in the online layout, but when I use the Printable=Yes, skip the srcset link which is created and instead use the src link which is the original size. OOZ.MOO (talk) 09:33, 16 July 2019 (UTC)
That sounds like you need to file a task in phabricator and ping @Pastakhov, the maintainer of the extension. MarkAHershberger(talk) 17:30, 16 July 2019 (UTC)
Ok I'll try to do that. But is it not possible to do something in the Skins CSS stylesheets? Cause basically what I do is I generate the outputs to PDF by sending the %pagelink&action=mpdf&useskin=MonoBook, and I made a little bit of changes to this Skin only for the PDF output, but it's not my default Skin. So I thought if that would be possible to change the image sizes only in MonoBook skin, through CSS that might be possible. OOZ.MOO (talk) 09:05, 17 July 2019 (UTC)
That is a question for someone who knows more about CSS and the mpdf extension than I do. I think it should be possible, but I'm don't know enough about how mpdf operates to tell you. MarkAHershberger(talk) 14:27, 17 July 2019 (UTC)
@Pastakhov seems a bit unresponsive. I already asked another question a few months ago and still haven't received any response.
But I've got another question which might help me achieve what I need and you might be able to help. I've been looking into the #If Parser syntaxes.
My idea was that maybe I can add a #if syntax to the images syntax that check: If %weblink&printable=yes then {img=imagelink.png} and else {img=imagelink.png|728px}
But I don't know if that is possible somehow? I didn't quite understand how the #if parser functions work. I would appreciate it if you give me some hints on that.

OOZ.MOO (talk) 13:44, 25 July 2019 (UTC)
The parser functions are not meant to work like that. You would be better off using JS and/or updating the PHP in the mpdf extension. MarkAHershberger(talk) 14:24, 25 July 2019 (UTC)
Hi all, sorry for my bit unresponsive. Of course everything is possible, but there is no easy way to do that (increasing image resolution in PDF file). The Mpdf extension just sends printable version of wiki page to the mpdf library for rendering pdf file. Maybe some hooks allow to change resolution of files for printable version, I don't know... Maybe it would be the easiest way to resolve it Pastakhov (talk) 18:34, 4 August 2019 (UTC)
Hey @Pastakhov sorry also for my late reply.
The question is where does Mpdf gets the images links from? cause when you define a pixel rate for your image in mediawiki, it creates a multiple image links (visible in the html version of the printable version also) from all the different sizes available for the image. So to be more clear, when you have a image with originally 1920px, and you set it to 1200px in mediawiki, you get different links in your html, with 1920 and 1200 and 720px and so on. This is a function mediawiki has for responsive images.
So the question is, where in the codes does mpdf decides to get the image link? cause if I would know that, then maybe I could change the decision, to the highest resolution available.
I've been searching for it in the dark in your source codes but had so far no luck. Would be in a world of appreciation if you could help me with it. OOZ.MOO (talk) 11:41, 21 August 2019 (UTC)

Why 1.33 is not displayed as latest stable in Special:ExtensionDistributor?

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


In Special:ExtensionDistributor/Echo, you can see 1.32 is selected as 'latest stable MediaWiki' by default while 1.33 is marked as 'next stable candidate'. Is it intended? If not, where and how do I report this? Thanks. Lens0021 (talk) 16:08, 15 July 2019 (UTC)

You can file a task in phabricator for this. MarkAHershberger(talk) 16:26, 15 July 2019 (UTC)
I am following Gerrit/Tutorial and has published a patch I think... Lens0021 (talk) 09:59, 16 July 2019 (UTC)
Looks good... Thanks! MarkAHershberger(talk) 17:22, 16 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

How to remove a page

How can I remove a page that is incorrect. 23.115.12.250 (talk) 18:28, 15 July 2019 (UTC)

You can't "remove" a page, but an administrator can delete it DannyS712 (talk) 18:37, 15 July 2019 (UTC)

Add textContent to HTML via MediaWiki template

I created a MediaWiki template named by the Hebrew letter א (template:א):
<code></code>
I call it by {{א|SOME_textContent}}.

The problem is that after I save the page, I get an empty <code> tag content ( ).

Why do I get empty <code> tag content ( ), instead getting SOME_textContent (the input I gave in call after the vertical bar) ?
49.230.76.81 (talk) 22:16, 15 July 2019 (UTC)

You get the contents of the template. Add {{{1}}} in the template where you want the first parameter to be substituted. See help:Templates for more info. Bawolff (talk) 02:16, 16 July 2019 (UTC)
@Bawolff I tried that but it didn't help, please see in Stackoverflow (because the automatic spam filter prevents me from pasting the link here):
Add textContent to HTML via MediaWiki template 49.230.75.149 (talk) 03:18, 17 July 2019 (UTC)
as @Tgr: said, = is special. Try making the parameter be 1== e.g. {{alef|1==}} (i dont have keyboard to actually type an alef and bidi is annoying) Bawolff (talk) 04:48, 17 July 2019 (UTC)

Logging In

I cannot log in and I know I exist, but the login says that there is no username that is mine. What gives? ~~~~Nacky 2600:1700:F0D0:7BA0:AC0C:E926:29A1:BD3F (talk) 23:52, 15 July 2019 (UTC)

- Check that you are placing the password correctly.
- Check that the name is well written, perfectly. AbelKnight (talk) 00:23, 16 July 2019 (UTC)

I can see the header but no content

I am using mediawiki a while now. Suddenly I can see the header but no text anymore. When I look in the database in the table .._text, I can see a few rows with blob type, which I can not read.

Can somebody help me with this issue. Any ideas?

Product Version
MediaWiki 1.33.0
PHP 7.2.20 (cgi-fcgi)
MariaDB 10.1.40-MariaDB-cll-lve
Ibrgk (talk) 12:49, 16 July 2019 (UTC)
Can you provide a link to your Wiki?
Did you recently did an upgrade?
When you open up the edit link of an article, is the content present in the editor? AhmadF.Cheema (talk) 14:58, 16 July 2019 (UTC)
As salam Aleykum Ahmed, did you find something weird on the page? Ibrgk (talk) 12:45, 17 July 2019 (UTC)
W/S. Sorry don't know enough to help. AhmadF.Cheema (talk) 16:33, 17 July 2019 (UTC)
Can you tell me which tables I have to export to an other mediawiki database to rescue the content of the site which is not working? vodiaal.com/mw Ibrgk (talk) 19:59, 17 July 2019 (UTC)
Probably Text table. AhmadF.Cheema (talk) 21:06, 17 July 2019 (UTC)
I did an upgrade recently.
http://vodiaal.com/mw/index.php?title=Main_Page is the link to the main page. which was filled with other links. When I want to edit an article, like the main page, it shows:
The revision #0 of the page named "Main Page" does not exist.
This is usually caused by following an outdated history link to a page that has been deleted. Details can be found in the deletion log.
When I look in the deletion log, there is nothing in it. Ibrgk (talk) 18:11, 16 July 2019 (UTC)
Did you run update.php after upgrading? Ciencia Al Poder (talk) 09:20, 19 July 2019 (UTC)

Media Viewer

Olá, quando eu clico para abrir a pré-visualização da imagem com Media Viewer, mas ao invés disso sou direcionado para a tela de descrição da imagem e tenho que voltar para continuar a leitura do documento.

querio saber se tem algo errado com minhas configurações ou meu código?! Gustavoambrosio (talk) 13:58, 16 July 2019 (UTC)

See Help:Extension:Media Viewer#How can I bypass Media Viewer? AhmadF.Cheema (talk) 15:14, 16 July 2019 (UTC)
Ja verifiquei, mas a versão do meu wiki não aparece a opção de ativar ou abrir no media viewer. Gustavoambrosio (talk) 16:34, 16 July 2019 (UTC)
thanks Gustavoambrosio (talk) 17:06, 16 July 2019 (UTC)

multiple domains pointing to the same wiki (apache/wiki configuration)

I have a wiki that is configured for short urls and just as I want it : some pages are readable by the world, the rest is just visible by those who work on the various projects it hosts. Let's say its url is mywiki.myinstitution.net

I ended up creating my webpage on that wiki and I want all the subpages of my user page to have the same domain name, which is different from the main wiki domain name (for instance me.myinstitution.com).

I started by defining rewriting rules with full urls :

#Current working (albeit redirect) configuration
<VirtualHost me.myinstitution.com:80>
    ServerName me.myinstitution.com
    RewriteEngine On
    RewriteRule "^/*$" "http://mywiki.myinstitution.net/wk/User:Me"
    RewriteRule "^(/.*)" "http://mywiki.myinstitution.net/wk/User:Me$1"
</VirtualHost>

but apache considers them as redirections, so they don't do exactly what I would like them to. The problem is that when I change them to the type of rewrites that will not be redirections, they obviously conflict with the global configuration of the wiki, and the pages are not even allowed access for anonymous users…

      #example of type of rewrite I would like, not that I know if it would work in any way
      #but I want  me.myinstitution.com to show exactly what mywiki.myinstitution.com/w/User:Me shows
      RewriteRule "^/*$" "/var/www/html/w/index.php/User:Me"

Is there hope to find a solution for my problem ?

NB : the configuration file looks like the following :

#Current working configuration
<VirtualHost mywiki.myinstitution.net:80>
    ServerName mywiki.myinstitution.net
    ServerAdmin me@myinstitution.net
    DocumentRoot /var/www/html
    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined
    <Directory /var/www/html/w/>
        Options FollowSymLinks        
    </Directory>
    RewriteEngine On
    RewriteRule ^/?wk(/.*)?$ %{DOCUMENT_ROOT}/w/index.php [L]
    # Redirect / to Main Page
    RewriteRule ^/*$ %{DOCUMENT_ROOT}/w/index.php [L]
</VirtualHost>

Thanks for any input… Loizbec (talk) 16:30, 16 July 2019 (UTC)

Have a look at MEZA, a deployment system put together by some MediaWiki administrators at NASA for managing multiple wikis (with different access needs) for their own use. MarkAHershberger(talk) 17:38, 16 July 2019 (UTC)
It seems very powerful, but it does not seem to say it does what I need… Loizbec (talk) 14:33, 24 July 2019 (UTC)
In LocalSettings.php add some code that looks at what the current path is (via $_SERVER) and uses an if statement to set $wgServer
Its quite a bit more complex if you want to also change the article/script path Bawolff (talk) 23:25, 16 July 2019 (UTC)
Very good idea to have separate configurations based on the http query. But I haven't found out how to restrict a wiki to a specific namespace (or more precisely to a page and its subpages), too many variables to consider :
  • apache rewrite rules ;
  • scriptPath ;
  • articlepath ;
  • etc.
If I could configure my wiki so that the root of the wiki is the article User:Me and that every other query is a subpage of that, I'd probably be able to make the if statement necessary for my multiple wikis, but I don't understand mediawiki enough…
Thanks anyway
Loizbec (talk) 14:26, 24 July 2019 (UTC)
So to sum up, I would need a configuration that would restrict my wiki to the subpages of my User page :
  • http://me.myinstitution.com points to the article User:Me of the wiki (formerly known as http://mywiki.myinstitution.com/w/User:Me)
  • http://me.myinstitution.com/subpage points to the article User:Me/subpage of the wiki (formerly known as http://mywiki.myinstitution.com/w/User:Me/supbpage) Loizbec (talk) 14:26, 24 July 2019 (UTC)
Hi @Loizbec, did you found a solution to do it ? Thanks a lot. Simonsarazin (talk) 13:28, 24 June 2021 (UTC)
Hi @Simonsarazin,
Sorry, I haven't replied earlier, I have postponed finding a solution to that problem for so long that it is just as if I have given up on it :-S.
If I ever relaunch that project, I'll keep you posted… Loizbec (talk) 09:34, 13 December 2021 (UTC)

Export uploads

When exporting all pages (via Special:Export) included pages starting with File:, the system only exports & imports the page bit not the File attached to that page, I get a empty page wuth option to upload a File to that page.

How can I export/import the page with its File attached ? 2610S (talk) 05:28, 17 July 2019 (UTC)

If you plan to export all images, you may want to try Manual:Grabbers (grabbers aren't adapted yet to MediaWiki 1.32 or newer). Ciencia Al Poder (talk) 09:18, 17 July 2019 (UTC)

Is it possible to show a page's category in search results?

Hi there, title says it all, is it possible?

For example, I want to show the page's category somewhere here > https://imgur.com/a/I4u3MpG


That page is part of the category "test", and I want that on search results the category is shown in the title, or in that "green text" of the box.

Thank you. 1337slash (talk) 09:11, 17 July 2019 (UTC)

You may try something like Extension:BreadCrumbs2 Ciencia Al Poder (talk) 09:15, 17 July 2019 (UTC)
I don't think that can help me.
As I said before, I want the category shown somewhere in the title, or in that green text box.
Like this > https://imgur.com/a/0KWxiFE (i used inspect element tool for little demonstration)
I don't know if that's possible... Maybe the solution is to edit the mediawiki core, and I'm not capable of doing that.
Anyway, thank you for the response. 1337slash (talk) 09:25, 17 July 2019 (UTC)

duplicate actor entry upgrading from 1.32 -> 1.33

The output that you posted says "Did you forget to run your application's database schema updater after upgrading?". That's the first idea...? Malyacko (talk) 19:20, 17 July 2019 (UTC)
Thanks Malyacko, but I got that error whilst it was upgrading. Unibond (talk) 04:40, 19 July 2019 (UTC)
This happens while running the application's database schema updater, as the topic states. It's happening also for me. 65.50.203.13 (talk) 21:28, 23 July 2019 (UTC)
I've created phab:T229092 for investigation. Any further information about how an actor ended up with an empty name would be greatly useful for resolving this problem. See also [[Project:Support desk/Flow/2019/07#h-Problems_when_upgrading_from_MW_1.29.2_to_MW_1.33.0_[Solved]-2019-07-25T19:47:00.000Z]] Ciencia Al Poder (talk) 09:26, 26 July 2019 (UTC)
If you would like any queries run please let me know. Unibond (talk) 14:11, 26 July 2019 (UTC)
Hi, I'm also experiencing the duplicate actor entry with MW1.33 after importing a MySQL dump from MW1.19. Update.php first complains about missing columns as described in T227662, for which I manually add the columns similarly to @Bttfvgo's workaround. Eventually I encounter the duplicate entry which I try deleting but the error repeats and the duplicate entry recreated. Rmnguyen (talk) 02:15, 30 July 2019 (UTC)
I guess for now the best solution is to set $wgActorTableSchemaMigrationStage = SCHEMA_COMPAT_OLD; in LocalSettings.php before running the update.php script until the bug is fixed. Ciencia Al Poder (talk) 09:30, 30 July 2019 (UTC)
Thanks, I tried adding $wgActorTableSchemaMigrationStage = SCHEMA_COMPAT_OLD; in LocalSettings.php and the update then completed when run from the command line.
However when I then tried to access the wiki ...
A database query error has occurred. Did you forget to run your application's database schema updater after upgrading?
Query: SELECT ipb_id,ipb_address,ipb_timestamp,ipb_auto,ipb_anon_only,ipb_create_account,ipb_enable_autoblock,ipb_expiry,ipb_deleted,ipb_block_email,ipb_allow_usertalk,ipb_parent_block_id,ipb_reason AS `ipb_reason_text`,NULL AS `ipb_reason_data`,NULL AS `ipb_reason_cid`,ipb_by,ipb_by_text,NULL AS `ipb_by_actor` FROM `ipblocks` WHERE ipb_address IN ('127.0.0.1','127.0.0.1') OR ((ipb_range_start LIKE '7F00%' ESCAPE '`' ) AND (ipb_range_start <= '7F000001') AND (ipb_range_end >= '7F000001'))
Function: Block::newLoad
Error: 1054 Unknown column 'ipb_reason' in 'field list' (127.0.0.1)

Unibond (talk) 17:27, 17 August 2019 (UTC)
Looks like you have an old MediaWiki extension installed, or an extension not compatible, because the ipb_reason column of the ipblocks table has been deleted in 1.33 and no code path should be accessing it.
Uninstall all extensions, try again, and enable them one by one until you find out which one is the correct one.
Another option may be that your database was upgraded to 1.33 but you rolled-back MediaWiki to 1.32. That's not supported and you'll get a broken wiki. Ciencia Al Poder (talk) 16:19, 18 August 2019 (UTC)

Cannot log in in wiwiwiki

Good day everyone,


unfortunately I can neither log in in wiwiwiki using my wiki account (Username S3maradd), nor create a new one as "I do not have the valid rights "to create a new account on wiwiwiki. Also, my username is not recognised on wiwiwiki. What could be wrong?


Many thanks


Margarita S3maradd (talk) 07:56, 18 July 2019 (UTC)

Unfortunately, wrong support forum.😕
Wiwiwiki is not related to this website. Maybe try their Contact us page. AhmadF.Cheema (talk) 09:16, 18 July 2019 (UTC)

Universal Language Selector does not detect the language of page content

Hi everyone,

I struggle a bit with the ULS package. I use the ULS together with the translate package and for the page contents etc. it works fine. But when it comes that the language is set to e.g. German and i click the Wiki-Logo, which leads to the English Main Page, the ULS is still set to German and not english. So also the sidebar contents remain german. Is this a bug or am i doing something wrong?


And one question off topic. Is it possible to have the ULS also in the sidebar like the extension "LanguageSelector" ? It would look so much better and would improve the handling as well.

Hopefully some of you have some advice.

Thanks in advance.

Best regards! :) Seehausen (talk) 08:14, 18 July 2019 (UTC)

These issues belong in as a task on Phabricator. Could you create one there and share the link with us here? MarkAHershberger(talk) 14:26, 18 July 2019 (UTC)

How reliable is MediaWIki? How to make MediaWiki more reliable?

Reliable like a page won't be lost. Can mediaWiki be more reliable without extensions? Shendaowu (talk) 08:30, 18 July 2019 (UTC)
Once you create a page in MediaWiki, the contents are stored in the database.
The only way a page could be "lost" by MediaWiki is if there is a bug that causes the deletion. If you run MediaWiki without any extensions, then a bug like that would be very, very, very surprising since people have used MediaWiki to store millions if not billions of pages.
A page could also be lost because of database corruption, but this, too, is extremely unlikely unless you have other problems with your physical computer. MarkAHershberger(talk) 13:47, 18 July 2019 (UTC)
Please provide clear information how you measure how "reliable" some software is.
In general, you can make MediaWiki (or your computer, or your car, or anything else) more reliable by finding wrong behavior and repairing that wrong behavior by making it right behavior. Malyacko (talk) 11:14, 18 July 2019 (UTC)
Are there any bugs that caused the page to be lost in the history of MediaWIki? Shendaowu (talk) 06:48, 20 July 2019 (UTC)
Maybe. I'm not familiar with any that have, but if you'd like to know you can search phabricator which contains all the reported bugs. (Here is one that was first reported in 2004 on SourceForge and then moved to Bugzilla and, finally, to Phabricator, for example.) MarkAHershberger(talk) 15:06, 20 July 2019 (UTC)

Anonymize imported WT user page

I've tried before to get the imported user page https://en.wikivoyage.org/wiki/User:(WT-en)_Schesis deleted, without success (it appears that my request to delete it was misinterpreted as a request to delete its talk page, given the following quote from said talk page:


> Warning: You are recreating a page that was previously deleted.

> 14:45, 19 April 2018 Ibaman talk contribs deleted page User talk:(WT-en) Schesis (per user request, content was: "Hi Schesis Welcome to Wikivoyage. Thank you for all your efforts in assisting with developing the content in the La Paz article.<br> To help new contributors understand how things work...")


I understand that it may be technically impossible to delete the user page without also deleting the "user" database entity and its associated contributions, and that this might be an onerous task. I would, however, like the page to be anonymized, so that my name no longer appears immediately after the introductory text "This is the imported user page of user ...". It seems to me that this ought to be a trivial operation.


If you follow the link to the WT user page that my WV user page was imported from, you'll see that I edited that page to remove references to my name at the same time that I last requested removal of the imported page here at WV.


If you need me to verify that I am the original author of the WT content which was automatically imported into WV under the username Schesis, I'm happy to do so, though I'll obviously need an email address to which I can send any proof of identity required. In a similar vein, since the point of this request is to anonymize the page in question, I'd appreciate it if responses in this public forum did not quote my name as currently displayed on that page.


Thanks for your help ... 90.255.190.108 (talk) 10:34, 18 July 2019 (UTC)

Hi. MediaWiki.org is about the MediaWiki software and does not cover ("social") deletion policies on other websites. My best idea is https://en.wikivoyage.org/wiki/Wikivoyage:Administrators and https://en.wikivoyage.org/wiki/Wikivoyage:Deletion_policy. Malyacko (talk) 11:12, 18 July 2019 (UTC)

Fatal exception of type MWUnknownContentModelException in flow page

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


Hi

in my wiki install flow extension after update to 1.33 version flow page show thi error

[XTC-PS78lpKtREeZjAhslwAAAAM] 2019-07-18 18:49:33: Fatal exception of type MWUnknownContentModelException

for debug in end of LocalSettings.php file add following:

$wgShowExceptionDetails = true;
$wgDebugToolbar = true;
$wgShowDebug = true;
$wgDevelopmentWarnings = true;
$wgShowDBErrorBacktrace = true;

but not show anything except :

[XTC-PS78lpKtREeZjAhslwAAAAM] 2019-07-18 18:49:33: Fatal exception of type MWUnknownContentModelException

please help me Beginneruser (talk) 18:56, 18 July 2019 (UTC)

I'm filing a phabricator task for this DannyS712 (talk) 18:59, 18 July 2019 (UTC)
in my log file is show message
[Thu Jul 18 23:27:05.146269 2019] [php7:error] [pid 11217] PHP Fatal error:  Uncaught Error: Class 'Pimple\\Container' not found in /home/wiki/web/site.com/public_html/w/extensions/Flow/includes/Container.php:5\nStack trace:\n#0 /home/wiki/web/site.com/public_html/w/includes/AutoLoader.php(109): require()\n#1 [internal function]: AutoLoader::autoload('Flow\\\\Container')\n#2 /home/wiki/web/site.com/public_html/w/extensions/Flow/includes/Content/BoardContentHandler.php(128): spl_autoload_call('Flow\\\\Container')\n#3 /home/wiki/web/site.com/public_html/w/includes/page/WikiPage.php(274): Flow\\Content\\BoardContentHandler->getActionOverrides()\n#4 /home/wiki/web/site.com/public_html/w/includes/actions/Action.php(98): WikiPage->getActionOverrides()\n#5 /home/wiki/web/site.com/public_html/w/includes/actions/Action.php(155): Action::factory('view', Object(WikiPage), Object(SkinVector))\n#6 /home/wiki/web/site.com/public_html/w/includes/skins/SkinTemplate.php(256): Action::getActionName(Object(SkinVector))\n#7 /home/wiki/web/fa.imamatped in /home/wiki/web/site.com/public_html/w/extensions/Flow/includes/Container.php on line 5, referer: https://site.com/wiki/User:Admin
Beginneruser (talk) 18:59, 18 July 2019 (UTC)
Reported at phab:T228463 DannyS712 (talk) 19:02, 18 July 2019 (UTC)
Do you have a composer.local.json? have you run composer update? MarkAHershberger(talk) 21:28, 18 July 2019 (UTC)
run composer install --no-dev in Flow Extension, then page of talk coming up
but show this error:
«Flow\Exception\UnknownWorkflowIdException»
then run php upadte.php in
[XTDqUjS2IWuGVrY8udHdHAAAAAA] /wiki/%D8%A8%D8%AD%D8%AB_%DA%A9%D8%A7%D8%B1%D8%A8%D8%B1:Bahmani Flow\Exception\UnknownWorkflowIdException from line 127 of /home/wiki/web/site.com/public_html/w/extensions/Flow/includes/WorkflowLoaderFactory.php: The requested workflow does not exist on this wiki.
Backtrace
#0 /home/wiki/web/site.com/public_html/w/extensions/Flow/includes/WorkflowLoaderFactory.php(103): Flow\WorkflowLoaderFactory->loadWorkflowById(Title, Flow\Model\UUID)
#1 /home/wiki/web/site.com/public_html/w/extensions/Flow/includes/Actions/Action.php(105): Flow\WorkflowLoaderFactory->createWorkflowLoader(Title)
#2 /home/wiki/web/site.com/public_html/w/extensions/Flow/includes/Actions/ViewAction.php(20): Flow\Actions\FlowAction->showForAction(string, OutputPage)
#3 /home/wiki/web/site.com/public_html/w/extensions/Flow/includes/Actions/Action.php(50): Flow\Actions\ViewAction->showForAction(string)
#4 /home/wiki/web/site.com/public_html/w/includes/MediaWiki.php(499): Flow\Actions\FlowAction->show()
#5 /home/wiki/web/site.com/public_html/w/includes/MediaWiki.php(294): MediaWiki->performAction(Article, Title)
#6 /home/wiki/web/site.com/public_html/w/includes/MediaWiki.php(865): MediaWiki->performRequest()
#7 /home/wiki/web/site.com/public_html/w/includes/MediaWiki.php(515): MediaWiki->main()
#8 /home/wiki/web/site.com/public_html/w/index.php(42): MediaWiki->run()
#9 {main}
Show message in command line
Adding index flow_tree_descendant_rev_id to table flow_tree_revision ...[408c90bce02610726990c1c8] [no req]   Wikimedia\Rdbms\DBQueryError from line 1587 of /home/wiki/web/site.com/public_html/w/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: DROP INDEX flow_tree_descendant_id_revisions ON `flow_tree_revision`
Function: Wikimedia\Rdbms\Database::sourceFile( /home/wiki/web/site.com/public_html/w/extensions/Flow/db_patches/patch-flow_tree_idx_fix.sql )
Error: 1091 Can't DROP 'flow_tree_descendant_id_revisions'; check that column/key exists (localhost)
Backtrace
#0 /home/wiki/web/site.com/public_html/w/includes/libs/rdbms/database/Database.php(1556): Wikimedia\Rdbms\Database->getQueryExceptionAndLog(string, integer, string, string)
#1 /home/wiki/web/site.com/public_html/w/includes/libs/rdbms/database/Database.php(1274): Wikimedia\Rdbms\Database->reportQueryError(string, integer, string, string, boolean)
#2 /home/wiki/web/site.com/public_html/w/includes/libs/rdbms/database/Database.php(4430): Wikimedia\Rdbms\Database->query(string, string)
#3 /home/wiki/web/site.com/public_html/w/includes/libs/rdbms/database/Database.php(4365): Wikimedia\Rdbms\Database->sourceStream(resource (closed), NULL, NULL, string, NULL)
#4 /home/wiki/web/site.com/public_html/w/includes/installer/DatabaseUpdater.php(690): Wikimedia\Rdbms\Database->sourceFile(string)
#5 /home/wiki/web/site.com/public_html/w/includes/installer/DatabaseUpdater.php(783): DatabaseUpdater->applyPatch(string, boolean, string)
#6 /home/wiki/web/site.com/public_html/w/includes/installer/DatabaseUpdater.php(489): DatabaseUpdater->addIndex(string, string, string, boolean)
#7 /home/wiki/web/site.com/public_html/w/includes/installer/DatabaseUpdater.php(457): DatabaseUpdater->runUpdates(array, boolean)
#8 /home/wiki/web/site.com/public_html/w/maintenance/update.php(203): DatabaseUpdater->doUpdates(array)
#9 /home/wiki/web/site.com/public_html/w/maintenance/doMaintenance.php(96): UpdateMediaWiki->execute()
#10 /home/wiki/web/site.com/public_html/w/maintenance/update.php(266): require_once(string)
#11 {main}
Now should me run SQL query DROP INDEX flow_tree_descendant_id_revisions ON `flow_tree_revision` in database? Beginneruser (talk) 22:05, 18 July 2019 (UTC)
It looks like @Catrope updated the code to produce the backtrace you're seeing for UnknownWorkflowIdException. That commit and the associated Phabricator task indicate that there is probably a problem in your DB structure.
Please read over comments on the Phab task and see if any of them help. MarkAHershberger(talk) 15:19, 19 July 2019 (UTC)
The error appears to be that it's trying to drop flow_tree_descendant_id_revisions but it doesn't exist. I'll upload a patch for Flow to handle this better, but it was probably caused by an aborted update.php run or some other strange thing like that.
In the meantime, you can try to fix this problem by running CREATE INDEX flow_tree_descendant_id_revisions ON flow_tree_revision (tree_rev_descendant_id, tree_rev_id); , then re-running update.php/ Catrope (talk) 22:44, 23 July 2019 (UTC)
Patch is here: https://gerrit.wikimedia.org/r/#/c/mediawiki/extensions/Flow/+/525170 Catrope (talk) 22:58, 23 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Is there a way to see if there are any "Information Islands"?

I found two articles that only link to each other. A to B, and B to A. Nothing else linked to A or B. This didn't show on any of my reports that I track, such as Special:DeadendPages, since they technically weren't dead end pages.
I'd like to ensure that there aren't any "information islands" and I would like to prioritize linking articles together so you could always (eventually) get from any random page to another random page. Is there a way I could see if there are any? Jer Hughes (talk) 20:57, 18 July 2019 (UTC)
I have not done this, but you could graph the connections between your articles and, from that, find tiny islands in your wiki. MarkAHershberger(talk) 21:18, 18 July 2019 (UTC)
I've seen graphs made of Wikipedia. I'm not sure how I could make my own. Jer Hughes (talk) 23:19, 18 July 2019 (UTC)
These are also called walled gardens. DannyS712 (talk) 21:00, 18 July 2019 (UTC)

Chinese variants conversion problems

In Chinese-translated pages on this site, every conversion markup works fine except the -{T|}- markup used for zh title conversions (same as {{DISPLAYTITLE:}} (namely Translations:Help:Extension:Translate/Translation_example/Page_display_title/zh in Help:Extension:Translate/Translation_example/zh), but {{DISPLAYTITLE:}} cannot make any conversions, so the -{zh:Chinese content;zh-hans:Simplified Chinese content;zh-hant:Traditional Chinese content;}- markup doesn't work in the Page_display_title section), maybe the problem is the page “Translations:Help:Extension:Translate/Translation_example/Page_display_title/zh transcluded in Help:Extension:Translate/Translation_example/zh” by Extension:Translate will override the -{T|}- markup, so neither the the -{T|}- markup parameter “T” in Template:NoteTA works.

How can we fix it, or maybe it's a bug? Winston Sung (talk) 02:04, 19 July 2019 (UTC)

This really belongs on Current issues so I've posted a note there. (pinging @Amire80 and @Nikerabbit since they know this area better than me.) MarkAHershberger(talk) 15:36, 19 July 2019 (UTC)
Thanks! Winston Sung (talk) 16:23, 20 July 2019 (UTC)
This question is more for @Nikerabbit as the Translate extension expert, and maybe even more so for @Cscott as an expert in both the Parser and the Language converter. Amir E. Aharoni {{🌎🌍🌏}} 11:21, 21 July 2019 (UTC)

TimedMediaHandler won't transcode anything

TimedMediaHandler won't transcode anything, am not really qualified to be making my own wiki, but so far i have gotten most things to work, this is one of two things i can't seem to get to work, am making a local only site just for me and my friends to screw around with, so it does not need to be able to handle work outside of the local network.

it keeps saying, failed transcodes, in the Special:TimedMediaHandler part of the site

i suspect that i might have not setup the locations of the trancoders properly, perhaps someone that knows more could check them for me...

$wgFFmpegLocation = 'C:/Bitnami/wampstack-7.1.30-0/ffmpeg413/bin';

windows location is.... C:\Bitnami\wampstack-7.1.30-0\ffmpeg413, do i included the bin that contains the exes?

$wgFFmpeg2theoraLocation = 'C:/Bitnami/wampstack-7.1.30-0/ffmpeg2theora';

windows location is.... C:\Bitnami\wampstack-7.1.30-0\ffmpeg2theora, exe is in the actual folder on this one.

$wgOggThumbLocation = 'C:/Bitnami/wampstack-7.1.30-0/php/OggTools/bin';

Windows location is... C:\Bitnami\wampstack-7.1.30-0\php\OggTools\bin, do i included the bin that contains the exes?


TimedMediaHandler 0.6.0 (5d59610)21:40, June 13, 2019


Installed software

Product Version
MediaWiki 1.32.1
PHP 7.3.7 (apache2handler)
MySQL 5.7.23
ICU 64.2
Lua 5.1.4


if anyone needs more information, please let me know what they need and i'll try get it for them. Eluphay (talk) 03:19, 19 July 2019 (UTC)

$wgFFmpegLocation should point to the full path of ffmpeg, not only the folder where it's placed. I guess it should be C:/Bitnami/wampstack-7.1.30-0/ffmpeg413/bin/ffmpeg.exe or similar. The same for other settings. Ciencia Al Poder (talk) 09:15, 19 July 2019 (UTC)
awesome, that seems to have solved the access problem, now i just need to fix my other issues Eluphay (talk) 06:50, 21 July 2019 (UTC)
am now getting this error instead,
Error creating thumbnail: "C:/Bitnami/ff/ffmpeg.exe" -threads 1 -ss 137 -y -i "C:\Bitnami\wampstack-7.1.30-0\apps\mediawiki\htdocs/images/b/b0/video.webm" -ss 3 -s 720x480 -f mjpeg -an -vframes 1 "C:\Windows\TEMP/transform_6ca548108731.jpg" 2>&1 wgMaxShellMemory: 32768000 The filename, directory name, or volume label syntax is incorrect. Eluphay (talk) 07:46, 21 July 2019 (UTC)
The problem seems to be the "2>&1" part of the command executed, which only works on bash shell (linux) and not on Windows. If you can locate it on the code, just remove it and it should work. That's worth a BUGREPORT Ciencia Al Poder (talk) 10:00, 21 July 2019 (UTC)
okay removed the 2>&1 part of the command in TimedMediaThumbnail.php,
now it just says...
Error creating thumbnail: "C:/Bitnami/ff/ffmpeg.exe" -threads 1 -ss 137 -y -i "C:\Bitnami\wampstack-7.1.30-0\apps\mediawiki\htdocs/images/b/b0/video.webm" -ss 3 -s 720x480 -f mjpeg -an -vframes 1 "C:\Windows\TEMP/transform_6ca548108731.jpg" 2>&1 wgMaxShellMemory: 32768000 Eluphay (talk) 10:47, 21 July 2019 (UTC)
There's still a 2>&1 somewhere... Ciencia Al Poder (talk) 11:30, 21 July 2019 (UTC)
Error creating thumbnail: "C:/Bitnami/ff/ffmpeg.exe" -threads 1 -ss 137 -y -i "C:\Bitnami\wampstack-7.1.30-0\apps\mediawiki\htdocs/images/b/b0/video.webm" -ss 3 -s 720x480 -f mjpeg -an -vframes 1 "C:\Windows\TEMP/transform_c415afd9e35c.jpg" wgMaxShellMemory: 32768000
got rid of it, still nothing Eluphay (talk) 12:12, 21 July 2019 (UTC)
i forgot to save the changes to TimedMediaThumbnail.php, i was being an idiot, sorry about that Eluphay (talk) 12:13, 21 July 2019 (UTC)
still nothing though Eluphay (talk) 12:13, 21 July 2019 (UTC)
Can you open CMD and execute the command directly?
"C:/Bitnami/ff/ffmpeg.exe" -threads 1 -ss 137 -y -i "C:\Bitnami\wampstack-7.1.30-0\apps\mediawiki\htdocs/images/b/b0/video.webm" -ss 3 -s 720x480 -f mjpeg -an -vframes 1 "C:\Windows\TEMP/transform_c415afd9e35c.jpg" Ciencia Al Poder (talk) 12:42, 21 July 2019 (UTC)
that works, but the server fails to do it itself Eluphay (talk) 17:23, 21 July 2019 (UTC)
Obviously their is nothing wrong with the command or ffmpeg then, the server is just not calling the command properly for some reason, what is it doing wrong?, is their a way to fix it? Eluphay (talk) 17:24, 23 July 2019 (UTC)
You can try to setup a debug log: Manual:How to debug#Setting up a debug log file
It should log the command being executed and potentially any output or error condition to give more information. Ciencia Al Poder (talk) 09:22, 24 July 2019 (UTC)
in the log its still saying the same error, however after i deleted 2>&1 from the php file, the only thing that seemed to change, is the showing of the error message on the page itself, but it still seems to be having this problem internally...
[exec] Error running "C:/Bitnami/ff/ffmpeg.exe" -threads 1  -ss 137 -y -i "C:\Bitnami\wampstack-7.1.30-0\apps\mediawiki\htdocs/images/b/b0/video.webm" -ss 3  -s 720x480 -f mjpeg -an -vframes 1 "C:\Windows\TEMP/transform_540f9f5c2317.jpg": The filename, directory name, or volume label syntax is incorrect. Eluphay (talk) 06:41, 25 July 2019 (UTC)
other part of this log was...
File::transform: Doing stat for mwstore://local-backend/local-thumb/b/b0/video.webm/120px--video.webm.jpg
[FileOperation] FileBackendStore::getFileStat: File mwstore://local-backend/local-thumb/b/b0/video.webm/120px--video.webm.jpg does not exist
Creating video thumbnail at C:\Windows\TEMP/transform_31d6904568a5.jpg
File::transform: Doing stat for mwstore://local-backend/local-thumb/b/b0/video.webm/720px-seek=140-video.webm.jpg
[FileOperation] FileBackendStore::getFileStat: File mwstore://local-backend/local-thumb/b/b0/video.webm/720px-seek=140-video.webm.jpg does not exist
Creating video thumbnail at C:\Windows\TEMP/transform_540f9f5c2317.jpg
[exec] MediaWiki\Shell\Command::execute: "C:/Bitnami/ff/ffmpeg.exe" -threads 1  -ss 137 -y -i "D:\Bitnami\wampstack-7.1.30-0\apps\mediawiki\htdocs/images/b/b0/video.webm" -ss 3  -s 720x480 -f mjpeg -an -vframes 1 "C:\Windows\TEMP/transform_540f9f5c2317.jpg"
[exec] Error running "C:/Bitnami/ff/ffmpeg.exe" -threads 1  -ss 137 -y -i "C:\Bitnami\wampstack-7.1.30-0\apps\mediawiki\htdocs/images/b/b0/video.webm" -ss 3  -s 720x480 -f mjpeg -an -vframes 1 "C:\Windows\TEMP/transform_540f9f5c2317.jpg": The filename, directory name, or volume label syntax is incorrect.

Eluphay (talk) 06:44, 25 July 2019 (UTC)
Can you try to change
C:/Bitnami/ff/ffmpeg.exe
to
C:\Bitnami\ff\ffmpeg.exe
In your LocalSettings.php?
Since \ is an escape character in PHP, you may need to use
C:\\Bitnami\\ff\\ffmpeg.exe Ciencia Al Poder (talk) 09:24, 25 July 2019 (UTC)
does not work, same error 185.43.110.30 (talk) 05:38, 27 July 2019 (UTC)
does not work, same error,
forgot to log in Eluphay (talk) 05:39, 27 July 2019 (UTC)
tried both \\, and \. Eluphay (talk) 05:39, 27 July 2019 (UTC)
The error The filename, directory name, or volume label syntax is incorrect is produced by the windows shell.
If executing "C:/Bitnami/ff/ffmpeg.exe" -threads 1  -ss 137 -y -i "D:\Bitnami\wampstack-7.1.30-0\apps\mediawiki\htdocs/images/b/b0/video.webm" -ss 3  -s 720x480 -f mjpeg -an -vframes 1 "C:\Windows\TEMP/transform_540f9f5c2317.jpg" from a command prompt doesn't produce this error, then the version of PHP you're using may have a bug invoking the shell. Ciencia Al Poder (talk) 17:26, 28 July 2019 (UTC)
does the $wgImageMagickConvertCommand variable use the shell?, because its loading convert.exe from imagemagik without problems Eluphay (talk) 11:57, 30 July 2019 (UTC)
Yes, it uses the shell Ciencia Al Poder (talk) 17:22, 30 July 2019 (UTC)
how come that works fine?, it the php version is not able to use the shell properly, then how does it managed with imagemagik? Eluphay (talk) 07:12, 1 August 2019 (UTC)
This is a problem with ffmpeg.exe
I've tried the same command on my PC, and changed C:/Bitnami/ff/ffmpeg.exe with notepad.exe, and I get the same error, but if I change it to calc.exe instead I don't get the error
ffmpeg (and notepad) seem to be interpreting something weirdly from the command that cause them to throw that error. Ciencia Al Poder (talk) 09:03, 1 August 2019 (UTC)
interesting..., any idea whats going on?, is it the text formatting or something? Eluphay (talk) 15:35, 1 August 2019 (UTC)
I don't know, but it doesn't make sense Ciencia Al Poder (talk) 17:38, 1 August 2019 (UTC)
is ffmpeg perhaps accepting text via the shell only when its encoded in unicode or ansi perhaps?, just theorising now. notepad i believe only supports ansi not unicode, ffmpeg probably does support unicode, probably useless, but am just trying to brainstorm here Eluphay (talk) 07:19, 2 August 2019 (UTC)
Notepad supports Unicode, though depending on the version, the default save format is likely to be ANSI. In recent Windows 10 builds, the default might have been set to Unicode now. AhmadF.Cheema (talk) 10:26, 2 August 2019 (UTC)
This doesn't seem to be a unicode issue, since the problem is caused when a path is passed to a program (in some programs it causes an error, in others it doesn't) Ciencia Al Poder (talk) 16:59, 2 August 2019 (UTC)
i haven't used notepad properly since windows 98, which i believe did not support Unicode in those days, obviously it does now, did not know that, good to know though.
either way we still need to figure out whats going on, i assumed that the path was likely not effected by text encoding, it was mostly a wild guess, as i can't think of anything else right now, am able to execute the command purely myself in the command prompt, so ffmpeg can use the command, it seems that the way its receiving the command is effecting it, if am understanding correctly.

Eluphay (talk) 09:53, 4 August 2019 (UTC)
still trying to fix this, still nothing yet Eluphay (talk) 02:46, 18 September 2019 (UTC)
finally got everything else on my site working, but this issue just won't go away Eluphay (talk) 07:18, 27 September 2019 (UTC)
Unfortunately this is something specific to windows and ffmpeg, probably not a common setup. If nobody else has a clue about this you may need to find help in other forums or stack overflow. Ciencia Al Poder (talk) 09:20, 27 September 2019 (UTC)
imagemagik cmd executed programs work fine, such as convert.exe, as do all other cmd programs, its just ffmpeg that refuses to work, according to task manager and process hacker, it seems its not even loading up at all, is it loaded within apache's httpd.exe or something, cause that seems kinda weird to me. Eluphay (talk) 14:06, 27 September 2019 (UTC)
seems that getting parsoid and nodejs to run on windows for the visualeditor is also very hard to do, as windows is an uncommon setup, however after a lot of hard work, its working perfectly now, that was my only other issue, now am left with just this one issue, audio playback works, and the videos play if pre-converted to the right format prior to upload and you go to the direct link to the file in the web-browser, however the generation of thumbnails and the trans-coding, just refuses to work. Eluphay (talk) 14:26, 27 September 2019 (UTC)

Can see thumbnails but not full-sized images

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


When I upload an image I can see the thumbnail in my article.


But when I click the thumbnail I cannot see the full-sized image.


Any idea as of why this would be happening? 86.49.182.250 (talk) 04:59, 19 July 2019 (UTC)

On viewing the full-sized image, does the Console section of the browser developer tools (F12) give any errors? AhmadF.Cheema (talk) 07:57, 19 July 2019 (UTC)
Hi, I'm getting the following errors in the Console section: imgur.com/Sa5qclT.png 86.49.182.250 (talk) 11:18, 19 July 2019 (UTC)
It looks like $wgServer or a related setting is wrong. It should not have "index.php" in it. MarkAHershberger(talk) 15:27, 19 July 2019 (UTC)
I just created an account.
My $wgServer line reads as following:
$wgServer = "h ttp: // example. com:9000";
I was having issues with it before so I had to edit it to include the port number since I'm not using port 80.
I'm still trying to isolate what could be causing this issue. TheBGPMan (talk) 10:36, 20 July 2019 (UTC)
Is index.php mentioned anywhere in your LocalSettings.php? If not, could you paste it here with your passwords removed? MarkAHershberger(talk) 14:58, 20 July 2019 (UTC)
I have edited the personal information, passwords and keys:
LocalSettings.php
<?php
# This file was automatically generated by the MediaWiki 1.33.0
# installer. If you make manual changes, please keep track in case you
# need to recreate them later.
#
# See includes/DefaultSettings.php for all configurable settings
# and their default values, but don't forget to make changes in _this_
# file, not there.
#
# Further documentation for configuration settings may be found at:
# https://www.mediawiki.org/wiki/Manual:Configuration_settings
# Protect against web entry
if ( !defined( 'MEDIAWIKI' ) ) {
    exit;
}
## Uncomment this to disable output compression
# $wgDisableOutputCompression = true;
$wgSitename = "EXAMPLE";
$wgMetaNamespace = "EXAMPLE";
## The URL base path to the directory containing the wiki;
## defaults for all runtime URL paths are based off of this.
## For more information on customizing the URLs
## (like /w/index.php/Page_title to /wiki/Page_title) please see:
## https://www.mediawiki.org/wiki/Manual:Short_URL
$wgScriptPath = "";
## The protocol and server name to use in fully-qualified URLs
$wgServer = "http://example.com:9000";
## The URL path to static resources (images, scripts, etc.)
$wgResourceBasePath = "{$wgScriptPath}/images";
## The URL path to the logo.  Make sure you change this from the default,
## or else you'll overwrite your logo when you upgrade!
$wgLogo = "$wgResourceBasePath/resources/assets/wiki.png";
## UPO means: this is also a user preference option
$wgEnableEmail = false;
$wgEnableUserEmail = false; # UPO
$wgEmergencyContact = "apache@ip_address";
$wgPasswordSender = "apache@ip_address";
$wgEnotifUserTalk = false; # UPO
$wgEnotifWatchlist = false; # UPO
$wgEmailAuthentication = true;
## Database settings
$wgDBtype = "mysql";
$wgDBserver = "localhost";
$wgDBname = "wikidb";
$wgDBuser = "root";
$wgDBpassword = "PASSWORD";
# MySQL specific settings
$wgDBprefix = "";
# MySQL table options to use during installation or update
$wgDBTableOptions = "ENGINE=InnoDB, DEFAULT CHARSET=binary";
## Shared memory settings
$wgMainCacheType = CACHE_ACCEL;
$wgMemCachedServers = [];
## To enable image uploads, make sure the 'images' directory
## is writable, then set this to true:
$wgEnableUploads = true;
$wgUseImageMagick = true;
$wgImageMagickConvertCommand = "/usr/bin/convert";
# InstantCommons allows wiki to use images from https://commons.wikimedia.org
$wgUseInstantCommons = true;
# Periodically send a pingback to https://www.mediawiki.org/ with basic data
# about this MediaWiki instance. The Wikimedia Foundation shares this data
# with MediaWiki developers to help guide future development efforts.
$wgPingback = false;
## If you use ImageMagick (or any other shell command) on a
## Linux server, this will need to be set to the name of an
## available UTF-8 locale
$wgShellLocale = "C.UTF-8";
## Set $wgCacheDirectory to a writable directory on the web server
## to make your wiki go slightly faster. The directory should not
## be publicly accessible from the web.
#$wgCacheDirectory = "$IP/cache";
# Site language code, should be one of the list in ./languages/data/Names.php
$wgLanguageCode = "en";
$wgSecretKey = "SECRETKEY";
# Changing this will log out all existing sessions.
$wgAuthenticationTokenVersion = "1";
# Site upgrade key. Must be set to a string (default provided) to turn on the
# web installer while LocalSettings.php is in place
$wgUpgradeKey = "UPGRADEKEY";
## For attaching licensing metadata to pages, and displaying an
## appropriate copyright notice / icon. GNU Free Documentation
## License and Creative Commons licenses are supported so far.
$wgRightsPage = ""; # Set to the title of a wiki page that describes your license/copyright
$wgRightsUrl = "";
$wgRightsText = "";
$wgRightsIcon = "";
# Path to the GNU diff3 utility. Used for conflict resolution.
$wgDiff3 = "/usr/bin/diff3";
# The following permissions were set based on your choice in the installer
$wgGroupPermissions['*']['createaccount'] = false;
$wgGroupPermissions['*']['edit'] = false;
$wgGroupPermissions['*']['read'] = false;
## Default skin: you can change the default skin. Use the internal symbolic
## names, ie 'vector', 'monobook':
$wgDefaultSkin = "timeless";
# Enabled skins.
# The following skins were automatically enabled:
wfLoadSkin( 'MonoBook' );
wfLoadSkin( 'Timeless' );
wfLoadSkin( 'Vector' );
# Enabled extensions. Most of the extensions are enabled by adding
# wfLoadExtensions('ExtensionName');
# to LocalSettings.php. Check specific extension documentation for more details.
# The following extensions were automatically enabled:
wfLoadExtension( 'CategoryTree' );
wfLoadExtension( 'Cite' );
wfLoadExtension( 'CiteThisPage' );
wfLoadExtension( 'CodeEditor' );
wfLoadExtension( 'Gadgets' );
wfLoadExtension( 'ImageMap' );
wfLoadExtension( 'InputBox' );
wfLoadExtension( 'Interwiki' );
wfLoadExtension( 'LocalisationUpdate' );
wfLoadExtension( 'MultimediaViewer' );
wfLoadExtension( 'Nuke' );
wfLoadExtension( 'OATHAuth' );
wfLoadExtension( 'ParserFunctions' );
wfLoadExtension( 'PdfHandler' );
wfLoadExtension( 'Poem' );
wfLoadExtension( 'Renameuser' );
wfLoadExtension( 'ReplaceText' );
wfLoadExtension( 'SyntaxHighlight_GeSHi' );
wfLoadExtension( 'WikiEditor' );
# End of automatically generated settings.
# Add more configuration options below.
wfLoadExtension( 'UserMerge' );
// By default nobody can use this function, enable for bureaucrat?
$wgGroupPermissions['bureaucrat']['usermerge'] = true;
// optional: default is array( 'sysop' )
$wgUserMergeProtectedGroups = array( 'groupname' );
#FOR UPLOADS
$wgUploadDirectory = "images";
$wgUploadPath = "images/img";
// Override the default with a bundle of filetypes:
$wgFileExtensions = array(
        'png', 'gif', 'jpg', 'jpeg', 'jp2', 'webp', 'ppt', 'pdf', 'psd',
        'mp3', 'xls', 'xlsx', 'swf', 'doc','docx', 'odt', 'odc', 'odp',
        'odg', 'mpp'
        );
$wgThumbnailScriptPath = "{$wgScriptPath}/thumb.php";
TheBGPMan (talk) 16:09, 20 July 2019 (UTC)
There's only one line with index.php but it's just a comment. TheBGPMan (talk) 16:11, 20 July 2019 (UTC)
Do you have short urls enabled on your wiki? Or anything in a .htaccess file at the top level? MarkAHershberger(talk) 20:06, 20 July 2019 (UTC)
Your problem is likely the $wgUploadDirectory and/or $wgUploadPath. You probably want something like:
$wgUploadDirectory = "$IP/images";
$wgUploadPath = "$wgScriptPath/images/img";
MarkAHershberger(talk) 20:11, 20 July 2019 (UTC)
Hi Mark, sorry for the delayed response. I just came back home.
You were right on point, I changed those fields to the following:
$wgUploadDirectory = "$IP/images/img";
$wgUploadPath = "$wgScriptPath/images/img";
And now everything is working just fine.
Thanks a lot! TheBGPMan (talk) 20:21, 20 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Mobile mode does not display content

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


https://meta.m.miraheze.org/wiki/Terms_of_Use doesn't display anything, even though the non-mobile page https://meta.miraheze.org/wiki/Terms_of_Use works? Reception123 (talk) 05:31, 19 July 2019 (UTC)

Also, looking at the mobile edit versions of the pages ManageWiki and Gazetteer of wikis only content before the first section gets displayed.🤔 AhmadF.Cheema (talk) 07:56, 19 July 2019 (UTC)
Yes, when editing only one part of the content (before first section) is there for some reason. How can this be explained? Reception123 (talk) 14:39, 19 July 2019 (UTC)
This is a problem that you need to take up with the people at Miraheze. They should check their log files for php errors. MarkAHershberger(talk) 15:24, 19 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Sphinx (Read the Docs) Documentation conversion to Mediawiki ?

Hello Friends,

i am new to this so please bare with me: I was presented a documentation which was made in Sphinx and uses the "read the Docs" theme. Now i am not familiar with any of this but i was asked to set up a Mediawiki where all that stuff should be transfered to. Now i am asking you if anyone knows how i could pull that off ? Is there any way i can convert every "Page" of the Sphinx/RtD Documentation into my wiki ?


Thanks in Advance Sevan2911 (talk) 07:16, 19 July 2019 (UTC)

Manual:Importing external content Malyacko (talk) 13:32, 19 July 2019 (UTC)

The problem of the default language that is showing in zh wikipedia website

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


‘Zh’ usually mean traditional-Chinese on most of the websites and games, etc. If the website is going to show simplified-Chinese, people usually represent it by showing ‘cn’ instead of ‘zh’ on the link. I wonder why it will show simplified-Chinese as a default language while I am using ‘zh’ version of wikipedia. Could anyone please fix it? this is bothering me since a long time ago. 14.0.228.224 (talk) 10:54, 19 July 2019 (UTC)

Feel free to provide a reference for your statement that "Zh usually means traditional-Chinese". Because others might disagree.
What you describe has nothing to do with the default code in the MediaWiki software (that's what this Support Desk is for), but with the configuration of some Wikipedia website.
Have you brought up this topic on a discussion page of the Chinese Wikipedia(s)? Because that's where you'll have to find consensus first. See https://meta.wikimedia.org/wiki/Requesting_wiki_configuration_changes Malyacko (talk) 13:30, 19 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Mobile Version Subdomain

hello, greetings to the support I need your help, I have a domain which is sourcewiki.org which is mounted on mediawiki and I also want to have a mobile version which is m.sourcewiki.org I already have the theme for mobile and the subdomain M just need to relate the two domains that when published on sourcewiki.org is also published on m.sourcewiki.org as well as automatically someone between sourcewiki.org from a mobile device redirects you to m.sourcewiki.org, THANK YOU VERY MUCH THANK YOU VERY THANK YOU AGAINST sourcewiki.org from a mobile device redirects you to m.sourcewiki.org, THANK YOU VERY YOU!

please give me the code... Samuelwiki12 (talk) 13:49, 20 July 2019 (UTC)

Checkout Extension:MobileFrontend MarkAHershberger(talk) 14:55, 20 July 2019 (UTC)

Mobile version m.sourcewiki.org error 404

hello everyone, now I just need that everything I publish on sourcewiki.org is published on m.sourcewiki.org Samuelwiki12 (talk) 16:55, 20 July 2019 (UTC)

You will need to set $wgMobileUrlTemplate, probably along with some rewrite rules.
Possible relevant links: Configuring browser auto-detection, #Using mod rewrite to force mobile view in mobile subdomain, Project:Support desk/Flow/2013/10#h-Extension:mobilefrontend_2-2013-10-20T14:53:00.000Z.
This sub-domain setup is probably more trouble than its worth for small Wikis. AhmadF.Cheema (talk) 19:01, 20 July 2019 (UTC)

30 days more and my editing is still review

Please help me,

I have 3 article ,I edited them, but still review.


why this review take more longer than usual ? thanks 140.0.94.89 (talk) 17:32, 20 July 2019 (UTC)

can you elaborate? You don't appear to have made other edits to this site, no I'm assuming you are talking about a different wiki DannyS712 (talk) 17:55, 20 July 2019 (UTC)

"MediaWiki:Cite references prefix" no longer exists -> how to add headline to citations?

Needs to be done via jQuery for example, see thread.

I use <references /> in a template for all my articles. If there's at least one reference in the wikitext, the references are shown and via MediaWiki:Cite references prefix a headline was shown for the references. This worked fine in MediaWiki 1.27.

Now I updated to MediaWiki 1.31 and I found that MediaWiki:Cite references prefix no longer exists. What is the new equivalent to it?

Extension:Cite doesn't say anything about it. Stefahn (talk) 19:36, 20 July 2019 (UTC)

It was removed in 2017, MW 1.29. See this phab task for details and help moving. MarkAHershberger(talk) 20:34, 20 July 2019 (UTC)
Thanks. I tried <references responsive="" /> but it doesn't change my code. I get <div class="mw-references-wrap mw-references-columns"> with <references /> as well.
Also, <references responsive="" /> doesn't add a headline and the task says nothing about "MediaWiki:Cite references prefix"... Stefahn (talk) 19:01, 23 July 2019 (UTC)
The change to implement this also removed the cite_references_prefix key.
The comment on the commit contains this bit:

* Deprecate cite_references_prefix/cite_references_suffix.

This message is rarely used and opens up compatibility hazards. It was already removed by Parsoid, but the PHP implementation still had it. It's typically used to add inline styles to the wrapper which is more appropiately done in Common.css (or obsoleted as part of the skin or Cite extenion itself nowadays depending on what style in question). It was also a HTML-style message with separated open and close segments, which is an anti-pattern in itself.
MarkAHershberger(talk) 23:13, 23 July 2019 (UTC)
Okay, thanks for the info.
Any suggestion how I can add a headline automatically if there are references in the wikitext? I could do via jquery's before but that feels like a hack... Stefahn (talk) 13:33, 24 July 2019 (UTC)
This StackOverflow answer shows a way to do it with CSS or jQuery. MarkAHershberger(talk) 16:01, 24 July 2019 (UTC)
Okay, thanks.
I used this code now in my Common.js and it works fine:
$(document).ready(function(){
    $('.mw-references-wrap').before('<h2>References</h2>');
});
Stefahn (talk) 14:27, 26 July 2019 (UTC)

Supported MySql version for mediawiki 1.26.4

Hi,
We are using our wiki site with the following software versions. We are planning to move our MySql version to MySql 8 or latest and am not sure this is supported for Mediawiki and if there's any underlying configuration changes needed from Wiki to connect to MySql. Please help me with some insights.
Product Version
MediaWiki 1.26.4
PHP 5.6.14 (cgi-fcgi)
MySQL 5.6.25-log
Abhishek Manjunath (talk) 06:45, 22 July 2019 (UTC)
You should update your wiki after (or before) you update your DB. The current LTS is 1.31. MarkAHershberger(talk) 13:41, 22 July 2019 (UTC)
Thanks Mark for your reply,
We have one query - Can we keep Mediawiki in same version post upgrade DB ? Abhishek Manjunath (talk) 06:16, 24 July 2019 (UTC)
Bawolff says you can, but you should know we don't support MediaWiki that old. See the lifecycle documentation. MarkAHershberger(talk) 16:07, 24 July 2019 (UTC)
You can look at the INSTALL file included with mediawiki for version requirements. MediaWiki 1.26.4 will definitely work with mysql 8, requiring only 5.0.3 or higher Bawolff (talk) 08:05, 22 July 2019 (UTC)

rev_timestamp: must be a valid

Hello friends good day

I have a very serious problem after updating from 1.28 to 1.33 and it's timestamp error, which makes it impossible to search and many of our encyclopaedia articles to be displayed correctly.

Please help us


ink of 1.32  :http://wikijoo.ir/32

link of 1.28:http://wikijoo.ir

1.32.0
PHP 7.0.33-0ubuntu0.16.04.5 (apache2handler)
MySQL 5.7.25-0ubuntu0.16.04.2
ICU 55.1
Lua 5.1.5

MediaWiki internal error.

Original exception: Wikimedia\Assert\ParameterAssertionException from line 63 of /var/www/html/32/vendor/wikimedia/assert/src/Assert.php: Bad value for parameter $row->rev_timestamp: must be a valid timestamp


best regards Erfansol (talk) 03:36, 23 July 2019 (UTC)

How did you upgrade? It looks like you have the wrong version of a library.
Can I ask why you're going to 1.32 instead of the recently-released 1.33? MarkAHershberger(talk) 16:14, 23 July 2019 (UTC)
upgrade same upgrade guide in mediawiki(dump sql,install new files,image,...)
i check both version 1.32/1.33 and error still running 188.121.147.102 (talk) 05:30, 24 July 2019 (UTC)
Could you post the full backtrace of the error? MarkAHershberger(talk) 16:14, 24 July 2019 (UTC)
The error comes from this line in RevisionStoreRecord.php line 73 :
       Assert::parameter( is_string( $timestamp ), '$row->rev_timestamp', 'must be a valid timestamp' );
when using timestamps like "20080323009267" for which is_string returns false.
maybedatabase format has changed and not beeing upgraded ? Cann anyone tell the data format from tabe revision.rev_timestamp ? 212.53.226.26 (talk) 09:59, 8 November 2019 (UTC)
btw. commenting that line helps...but i doubt it is the best idea 212.53.226.26 (talk) 10:20, 8 November 2019 (UTC)
Are you @Erfansol? If so, could you log in to update the information? If not, please create a new post. MarkAHershberger(talk) 16:02, 8 November 2019 (UTC)

Error creating thumbnail:bin/bash: /usr/bin/convert, No such file or directory

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


Hello Friends,

While we are trying to upload images to one of our wiki page , getting the below error.

"Error creating thumbnail:bin/bash: /usr/bin/convert, No such file or directory

Error code: 127"

Could you please advise on resolving this issue 199.228.98.65 (talk) 09:15, 23 July 2019 (UTC)

See Manual:Errors and symptoms#Using ImageMagick. Where are the executable binaries of ImageMagick installed on your machine? Malyacko (talk) 09:54, 23 July 2019 (UTC)
Getting this error and I don’t even have ImageMagick, I would think MediaWiki would come with something like this. FatalFit (talk) 14:56, 29 June 2023 (UTC)
Well of course you will get an imagemagick missing error if you dont have image magick.
If you dont wang to use image magick, set $wgUseImageMagick =false; in LocalSettings.php Bawolff (talk) 21:30, 29 June 2023 (UTC)
Yea I've put that in my LocalSettings.php and everything you could ever imagine but I've still been getting the error FatalFit (talk) 21:44, 29 June 2023 (UTC)
Can you post your LocalSettings.php ? What type of file formats are giving this error? Bawolff (talk) 03:25, 30 June 2023 (UTC)
Everything works but SVG (almost ever file on my site), here is my upload settings:
## UPLOADS
$wgEnableUploads = true; # Enable uploads
$wgGroupPermissions['user']['upload'] = false; # Restrict uploads
$wgGroupPermissions['bureaucrat']['upload'] = true; # Bureaucrats only
$wgGroupPermissions['user']['reupload'] = false; # Restrict upload overwrite
$wgFileExtensions = [ 'png', 'gif', 'jpg', 'jpeg', 'doc', 'webp', 'svg']; # Upload types
$wgUseImageMagick = false; # Disable ImageMagick
FatalFit (talk) 03:30, 30 June 2023 (UTC)
SVGs are controlled by $wgSVGConverter not $wgUseImageMagick. However you need to have some other converter if not image magick. MediaWiki does not support sending svgs directly (Although you can use Extension:NativeSvgHandler for that). Bawolff (talk) 07:13, 30 June 2023 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

what is alternate for Extension:SmoothGallery ?

HI,
We have been upgraded our MediaWiki to the available LTS version of MediaWiki as follows.
But, we notice the SmoothGallery extension is not working any more. Could you let know which would be the alternate extension for SmoothGallery ?

==Installed software==
Product Version
MediaWiki 1.31.1
PHP 7.1.8 (apache2handler)
MySQL 5.6.40
ICU 50.1.2
Thank you !
Sanjay SanjayKSahu (talk) 10:31, 23 July 2019 (UTC)
Since it isn't currently maintained, you can contact the author or a professional to get it upgraded so it works. MarkAHershberger(talk) 16:11, 23 July 2019 (UTC)
For inbuilt option see, Help:Images#Rendering a gallery of images. For third-party extensions, see Category:Image gallery extensions.
If these don't work for you, then you'll probably be out of luck. AhmadF.Cheema (talk) 15:55, 23 July 2019 (UTC)
Actually I got Extension:HoverGallery can be an alternate for Extension:SmoothGallery . And it's working expected for MediaWiki v1.13.1 SanjayKSahu (talk) 08:21, 2 August 2019 (UTC)

Regarding 'Extension:Thanks'

Is it possible to show the number of 'Thanks' a comment received besides the 'Thank' link?

Can the number of 'thanks' be stored in a variable or in database and can be displayed for each comment? 103.118.50.4 (talk) 17:56, 23 July 2019 (UTC)

I don't think any such system exists yet.
See Special:Log/thanks and Extension:Thanks#Log Documentation for related info. AhmadF.Cheema (talk) 22:54, 23 July 2019 (UTC)

Question about case sensivity of page names

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


At the moment I am creating severeal templates in this wiki here (MW 1.31.3). One existing template - because its set to german langauge, they are called Vorlage; this means template - one existing template is called Vorlage:NIV-II with an upper case I at its end. Then I want to create another template called Vorlage:NIV-Ii with a lower case i at its end. I entered this Vorlage:NIV-Ii in the search field and immediately the Vorlage:NIV-II template poped up. After that I created a template named Vorlage:NIV-Iie. This worked fine. Thereafter I moved the Vorlage:NIV-Iie template to Vorlage:NIV-Ii. This worked fine, too. Now both templates are alive and kicking. The question is: why was I not able to create the template with the lower case i in the first place? Is there a little gremlin at work?

Many thanks for an illuminating answer in advance! Wgkderdicke (talk) 20:35, 23 July 2019 (UTC)

I'm not sure why. It sounds like a bug. If you report it, could you link to the bug here? MarkAHershberger(talk) 17:57, 24 July 2019 (UTC)
When you perform a search (go search) it tries to get the exact title first, and if not, it tries a case-insensitive search. Only if the case-insensitive search fails it would display you the search results page and a link to create that page. Ciencia Al Poder (talk) 09:16, 26 July 2019 (UTC)
I see. If I am elsewhere in the wiki and I insert a nonexistent page name in the upper right search field, it performs a case-insensitive search and if an almost identical page is found, this almost identical page is displayed. If I click the magnifier icon in the search field, I am redirected to the special page Search. The same search input there gives me the search results and a link to create this searched but nonexistent page. Wgkderdicke (talk) 18:02, 26 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

LDAP Authentication fails

Hello,

I tried to set up the LDAP stack (Pluggable_Auth, LDAPProvider, LDAPAuthorization and LDAPAuthentication2) in my wiki. Unfortunately, instead of the Special:Login page this appears:

[39651157031d2b3781e8a606] /testwiki/index.php?title=Spezial:Anmelden&returnto=Hauptseite   LogicException from line 762 of /srv/www/htdocs/testwiki/includes/specialpage/AuthManagerSpecialPage.php: invalid field type:
Backtrace
#0 /srv/www/htdocs/testwiki/includes/specialpage/AuthManagerSpecialPage.php(675): AuthManagerSpecialPage::mapFieldInfoTypeToFormDescriptorType(NULL)
#1 /srv/www/htdocs/testwiki/includes/specialpage/AuthManagerSpecialPage.php(648): AuthManagerSpecialPage::mapSingleFieldInfo(MediaWiki\Extension\LDAPAuthentication2\ExtraLoginFields, integer)
#2 /srv/www/htdocs/testwiki/includes/specialpage/LoginSignupSpecialPage.php(659): AuthManagerSpecialPage->fieldInfoToFormDescriptor(array, array, string)
#3 /srv/www/htdocs/testwiki/includes/specialpage/AuthManagerSpecialPage.php(400): LoginSignupSpecialPage->getAuthForm(array, string)
#4 /srv/www/htdocs/testwiki/includes/specialpage/LoginSignupSpecialPage.php(313): AuthManagerSpecialPage->trySubmit()
#5 /srv/www/htdocs/testwiki/includes/specialpage/SpecialPage.php(569): LoginSignupSpecialPage->execute(NULL)
#6 /srv/www/htdocs/testwiki/includes/specialpage/SpecialPageFactory.php(558): SpecialPage->run(NULL)
#7 /srv/www/htdocs/testwiki/includes/MediaWiki.php(288): MediaWiki\Special\SpecialPageFactory->executePath(Title, RequestContext)
#8 /srv/www/htdocs/testwiki/includes/MediaWiki.php(865): MediaWiki->performRequest()
#9 /srv/www/htdocs/testwiki/includes/MediaWiki.php(515): MediaWiki->main()
#10 /srv/www/htdocs/testwiki/index.php(42): MediaWiki->run()
#11 {main}

This is what I have in my LocalSettings.php:

#LDAP Extension
wfLoadExtension ( 'PluggableAuth' );
wfLoadExtension ( 'LDAPProvider' );
wfLoadExtension ( 'LDAPAuthentication2' );
#wfLoadExtension ( 'LDAPAuthorization' );
$wgPluggableAuth_EnableLocalLogin = false;
$wgPluggableAuth_ExtraLoginFields = array (
        "Login" => array( "type" => "string", "label" => "Benutzername", "skippable" => false ),
        "Passwort" => array( "type" => "password", "label" => "Passwort", "skippable" => false, "sensitive" => true )
);
$wgPluggableAuth_ButtonLabel = "Anmelden";
$LDAPProviderDomainConfigs = "$IP/ldapprovider.json";
$LDAPAuthentication2AllowLocalLogin = false;
wfLoadExtension ( 'LDAPAuthentication2' );

Is there anything missing? Just in case, this is my JSON file for LDAPProvider:

{
   "testwiki": {
       "connection": {
           "server": "geo-infra.rlp",
           "port": 389,
           "enctype": "tls",
           "basedn": "ou=group,ou=VermKV,o=Landesverwaltung Rheinland-Pfalz,c=de",
           "userbasedn": "ou=group,ou=VermKV,o=Landesverwaltung Rheinland-Pfalz,c=de",
           "groupbasedn": "ou=group,ou=VermKV,o=Landesverwaltung Rheinland-Pfalz,c=de",
           "searchattribute": "uid",
           "usernameattribute": "uid",
           "realnameattribute": "cn",
           "emailattribute": "mail"
       },
       "authorization": {
           "rules": {
               "groups": {
                   "required":  "cn=wiki_testcontainer,ou=group,ou=VermKV,o=Landesverwaltung Rheinland-Pfalz,c=de"
               }
           }
       },
       "authentication": {
           "usernameattribute": "uid",
           "realnameattribute": "cn",
           "emailattribute": "mail"
       }
   }
}

Could anyone tell me which mistake(s) I made? Ablum010777 (talk) 05:58, 24 July 2019 (UTC)

@Osnard did a lot on this, and may know just by looking. MarkAHershberger(talk) 17:29, 24 July 2019 (UTC)
It may be a typo, but you have LDAPAuthentication2 loaded twice. Also, LDAPAuthorization is commented out (I don't know whether it's needed in your situation -- just looking for simple mistakes) Greg Rundlett (talk) 17:57, 24 July 2019 (UTC)
Does the problem still occur if you remove the following line:
$wgPluggableAuth_ExtraLoginFields = array (
        "Login" => array( "type" => "string", "label" => "Benutzername", "skippable" => false ),
        "Passwort" => array( "type" => "password", "label" => "Passwort", "skippable" => false, "sensitive" => true )
);
MarkAHershberger(talk) 18:05, 24 July 2019 (UTC)
Sorry, even by applying all your suggestions, the error still remains. :(
The things I did:
I removed the second line where LDAPAuthentication2 is loaded
I removed the PluggableAuth_ExtraLoginFields
I added the line where LDAPAuthorization is loaded.
Ablum010777 (talk) 05:52, 25 July 2019 (UTC)
That's strange. I can not find an obvious issue in the code Osnard (talk) 14:45, 25 July 2019 (UTC)

Warning: hash(): Unknown hashing algorithm: fnv132 in C:\wamp64\www\wiki\includes\resourceloader\ResourceLoader.php on line 624

My wiki was working fine until now, and suddenly this error is occuring.

MediaWiki 1.32.2
PHP 7.2.18 (apache2handler)
MySQL 5.7.26
ICU 63.1
103.118.50.4 (talk) 12:08, 24 July 2019 (UTC)
This is written in ResourceLoader.php
623:  public static function makeHash( $value ) {
624:  $hash = hash( 'fnv132', $value );
625:  return Wikimedia\base_convert( $hash, 16, 36, 7 );
626:  }
103.118.50.4 (talk) 12:12, 24 July 2019 (UTC)
Did you recently update WAMP? Could you put the following into test_hash.php on your wiki and verify that "fnv132" is among the results when you visit that php url on your wiki:
<?php
print_r( hash_algos() );
MarkAHershberger(talk) 17:18, 24 July 2019 (UTC)

Internal error on login page

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


[a18bdb061b8ec548837b2cf9] /index.php?title=Special:UserLogin&returnto=Main+Page&returntoquery= TypeError from line 39 of /var/www/html/SNRTwiki/includes/auth/PasswordDomainAuthenticationRequest.php: Argument 1 passed to MediaWiki\Auth\PasswordDomainAuthenticationRequest::__construct() must be of the type array, string given, called in /var/www/html/SNRTwiki/extensions/LdapAuth/src/Auth/PrimaryAuthenticationProvider.php on line 62

Backtrace:

#0 /var/www/html/SNRTwiki/extensions/LdapAuth/src/Auth/PrimaryAuthenticationProvider.php(62): MediaWiki\Auth\PasswordDomainAuthenticationRequest->__construct(string)

#1 /var/www/html/SNRTwiki/includes/auth/AuthManager.php(2100): Shanept\LdapAuth\Auth\PrimaryAuthenticationProvider->getAuthenticationRequests(string, array)

#2 /var/www/html/SNRTwiki/includes/auth/AuthManager.php(2078): MediaWiki\Auth\AuthManager->getAuthenticationRequestsInternal(string, array, array, User)

#3 /var/www/html/SNRTwiki/includes/specialpage/AuthManagerSpecialPage.php(256): MediaWiki\Auth\AuthManager->getAuthenticationRequests(string, User)

#4 /var/www/html/SNRTwiki/includes/specialpage/LoginSignupSpecialPage.php(141): AuthManagerSpecialPage->loadAuth(NULL)

#5 /var/www/html/SNRTwiki/includes/specialpage/LoginSignupSpecialPage.php(229): LoginSignupSpecialPage->load(NULL)

#6 /var/www/html/SNRTwiki/includes/specialpage/SpecialPage.php(569): LoginSignupSpecialPage->execute(NULL)

#7 /var/www/html/SNRTwiki/includes/specialpage/SpecialPageFactory.php(558): SpecialPage->run(NULL)

#8 /var/www/html/SNRTwiki/includes/MediaWiki.php(288): MediaWiki\Special\SpecialPageFactory->executePath(Title, RequestContext)

#9 /var/www/html/SNRTwiki/includes/MediaWiki.php(865): MediaWiki->performRequest()

#10 /var/www/html/SNRTwiki/includes/MediaWiki.php(515): MediaWiki->main()

#11 /var/www/html/SNRTwiki/index.php(42): MediaWiki->run()

#12 {main}


This is the error I am getting but I looked at PasswordDomainAuthenticationRequest.php on line 39 and the code is excatly the same from mediawiki's site. Not sure what this error is but it only happens when I have the LdapAuth extension turned on. I have done a composer install&&composer require symfony/ldap. As well as uncomment Extension = ldap from my php.ini file. I know my ldap bindname and password are correct as well as the domain name. Tmhoskins (talk) 14:46, 24 July 2019 (UTC)

It looks like you have a string in $wgLdapAuthDomainNames. Try changing it to an array. MarkAHershberger(talk) 16:30, 24 July 2019 (UTC)
Solved! Thanks Tmhoskins (talk) 17:10, 24 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Can't connect to Ldap Server at log in screen

Cannot connect to my Ldap server when logging in . LocalSettings.php config for LdapAuth are as follows:

# LdapAuth config
wfLoadExtension( 'LdapAuth' );
$wgLdapAuthDomainNames = ['snrt.io'];
$wgLdapAuthServers = '172.16.1.248';
$wgLdapAuthBindDN = 'CN=ldap_lookup,DC=snrt,DC=io';
$wgLdapAuthBindPass = 'my_password';
$wgLdapAuthBaseDN = 'DC=snrt,DC=io';
//$wgLdapAuthEncryptionType = 'clear';
//$wgLdapAuthRequireDomain = false;
//$wgLdapAuthIsActiveDirectory = true;
//$wgLdapAuthUseLocal = true;
#Enable Scure Login
$wgSecureLogin = true;
# Disable reading by anonymous users
$wgGroupPermissions ['*']['read'] = false;
$wgWhitelistRead = array ("Special:Userlogin", "Special:Version");
# Disable anonymous editing
$wgGroupPermissions ['*']['edit'] = false;
# Prevent new user registrations except by sysops
$wgGroupPermissions ['*']['createaccount'] = false;
$wgShowExceptionDetails = true;

I can log in locally if I turn on that feature. Tmhoskins (talk) 17:59, 24 July 2019 (UTC)

Can you connect from the web server itself to the ldapserver using ldapsearch on the command line?
What error are you getting? MarkAHershberger(talk) 18:11, 24 July 2019 (UTC)
Error when entering Ldap credentials:
"Could not successfully connect to an LDAP server." Tmhoskins (talk) 18:26, 24 July 2019 (UTC)
What OS is the server running on? Is there something (firewall, selinux,etc) blocking the webserver from connecting to the ldap server? MarkAHershberger(talk) 18:52, 24 July 2019 (UTC)
Running on Ubuntu 19.04. UFW is disabled, iptables is set to accept all, and selinux is disabled on the webserver. Domain Controller isn't blocking LDAP connections because our entire environment is set to use LDAP. I can ping the DC from the webserver and vice versa. I am having trouble binding to the LDAP server with ldapsearch. I can search the naming contexts on the server so it's obviously talking to the LDAP server just won't bind because it won't accept the password for my users account. So that could be my issue LDAP server may be blocking it. When I try to bind to the LDAP server this is the error I get:
$ ldapsearch -H ldap://coruscant.snrt.io -x -D "cn=Administrator,cn=Users,dc=snrt,dc=io" -W
Enter LDAP Password:
# extended LDIF
#
# LDAPv3
# base <> (default) with scope subtree
# filter: (objectclass=*)
# requesting: ALL
#
# search result
search: 2
result: 32 No such object
text: 0000208D: NameErr: DSID-031001EE, problem 2001 (NO_OBJECT), data 0, best
match of:
''
# numResponses: 1

Tmhoskins (talk) 12:42, 25 July 2019 (UTC)
Also checked the firewall running on the DC that is also the LDAP/AD server and all the LDAP ports:389, 636 are open to any connection.

Tmhoskins (talk) 13:01, 25 July 2019 (UTC)
Another note, I completely turned off the firewall on the LDAP/AD server and I still could not establish a connection from mediawiki. I assume something on the Ubuntu box is blocking it. Tmhoskins (talk) 13:56, 25 July 2019 (UTC)

Trying to upload an image, but the page does not allow me to choose licensing under the menu - FIXED

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


I´ve uploaded dozens images before, months ago. Now wanted to upload again, but the only option on the licensing drop down menu is 'none selected'. For some reason the images appear on my recent uploads, but the link on the page does not work 84.251.195.102 (talk) 18:33, 24 July 2019 (UTC)

NVM apparently my adblocker prevented the pic showing XD 84.251.195.102 (talk) 18:43, 24 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Report of access

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


Gostaria de saber se existe algum relatório que monitora os acessos as páginas do meu site? Gustavoambrosio (talk) 20:22, 24 July 2019 (UTC)

Extension:HitCounters Malyacko (talk) 08:09, 25 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Upgrade from 1.10.1 to 1.33.0

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


My company uses a Debian Server(Linux 2.618) with a MediaWiki 1.10.1 which has been in place, nearly untouched since 2007. Wanting to bring it to todays standards I've set up an Ubuntu Server with phpmyAdmin and MediaWiki 1.33.0 running. A backup of the old database should now be migrated to the new server.

I read the guides Restoring a wiki from backup and Upgrading, I must be missing something however. All the tables in the new databank are entirely different (more tables & columns within), therefore I was under the assumption, that by importing the tables into the new databank and running the update.php in the maintenance folder of the wiki should be sufficient in order to do this. That is not the case.

Is this approach feasible at all or am I simply better off trying to run an update on the old server? I would prefer the one I suggested if it's possible.

I would greatly appreciate any pointers towards the right direction. 213.23.90.238 (talk) 07:41, 25 July 2019 (UTC)

If I've understood correctly, you installed a new MediaWiki on the new server (you ran the setup and have now a working wiki) and now you want to import the old data to the new tables.
That's not how things should be done. Instead, you take a backup of the old database, and restore it on a new (empty/nonexistent) database (and new MediaWiki files) and then run the update.php script on the new database. Ciencia Al Poder (talk) 09:39, 25 July 2019 (UTC)
You did understand correctly. What you described is what I though I did but I must be getting something wrong.
So do you suggest I uninstall my new MediaWiki and purge the wiki database from phpmyadmin, place the 1.33.0 files in that location again, that I get the installation page when I try to access MediaWiki and then import the existing tables to a new database?
Am i then supposed to run the update.php before I continue the installation and then install the MediaWiki? 213.23.90.238 (talk) 10:16, 25 July 2019 (UTC)
  1. Do not remove your current new wiki.
  2. In phpMyAdmin:
    1. Drop the new wiki's current DB
    2. Create a new DB using the same name as the old one.
    3. Import the backup of the old DB into the new, empty DB.
  3. Go to the http://your-new-wiki/mw-config/ and run the DB migration script OR run update.php from the command line.
  4. Copy over any settings (including extensions which you'll have to upgrade) from your old wiki to your new one. MarkAHershberger(talk) 12:44, 25 July 2019 (UTC)
What Mark said. Also, if you run update.php before enabling/installing extensions, you'll need to run update.php again after you enable them. When you change hosts and upgrade from an old wiki that's probably a good idea, to try the upgrade first without extensions. Ciencia Al Poder (talk) 19:30, 25 July 2019 (UTC)
Excuse my late reply and thanks for answering.
The mw-config page only shows the finished installation screen to download my local settings file (which is already on the server). Restarting the installation simply inserts the new tables in the database which I imported the old ones into.
Running the update.php from the command line starts by creating a single table and then stops the process and is therefore unsuccessful too. Error message:
Adding default interwiki definitions ...[dd512c57fef802bbd63b2eca] [no req] Wikimedia\Rdbms\DBQueryError from line 1587 of /var/www/html/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?
Any ideas regarding this? 213.23.90.238 (talk) 09:32, 5 August 2019 (UTC)
Is the error message complete? It's missing the cause of the error. Try adding this to LocalSettings.php:
$wgShowSQLErrors = true;
$wgShowDBErrorBacktrace = true; Ciencia Al Poder (talk) 09:36, 5 August 2019 (UTC)
...ipblocks table does not exist, skipping new field patch.
...ipblocks table does not exist, skipping new field patch.
Creating interwiki table ...done.
Adding default interwiki definitions ...[edf831bd3c1f7c8ba0ae43f6] [no req]   Wikimedia\Rdbms\DBQueryError from line 1587 of /var/www/html/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: REPLACE INTO `interwiki` (iw_prefix,iw_url,iw_local,iw_api) VALUES
('acronym','https://www.acronymfinder.com/~/search/af.aspx?string=exact&Acronym=$1',0,''),
('advogato','http://www.advogato.org/$1',0,''),
('arxiv','https://www.arxiv.org/abs/$1',0,''),
('c2find','http://c2.com/cgi/wiki?FindPage&value=$1',0,''),
('cache','https://www.google.com/search?q=cache:$1',0,''),
('commons','https://commons.wikimedia.org/wiki/$1',0,'https://commons.wikimedia.org/w/api.php'),
('dictionary','http://www.dict.org/bin/Dict?Database=*&Form=Dict1&Strategy=*&Query=$1',0,''),
('doi','https://dx.doi.org/$1',0,''),
('drumcorpswiki','http://www.drumcorpswiki.com/$1',0,'http://drumcorpswiki.com/api.php'),
('dwjwiki','http://www.suberic.net/cgi-bin/dwj/wiki.cgi?$1',0,''),
('elibre','http://enciclopedia.us.es/index.php/$1',0,'http://enciclopedia.us.es/api.php'),
('emacswiki','https://www.emacswiki.org/cgi-bin/wiki.pl?$1',0,''),
('foldoc','https://foldoc.org/?$1',0,''),
('foxwiki','https://fox.wikis.com/wc.dll?Wiki~$1',0,''),
('freebsdman','https://www.FreeBSD.org/cgi/man.cgi?apropos=1&query=$1',0,''),
('gentoo-wiki','http://gentoo-wiki.com/$1',0,''),
('google','https://www.google.com/search?q=$1',0,''),
('googlegroups','https://groups.google.com/groups?q=$1',0,''),
('hammondwiki','http://www.dairiki.org/HammondWiki/$1',0,''),
('hrwiki','http://www.hrwiki.org/wiki/$1',0,'http://www.hrwiki.org/w/api.php'),
('imdb','http://www.imdb.com/find?q=$1&tt=on',0,''),
('kmwiki','https://kmwiki.wikispaces.com/$1',0,''),
('linuxwiki','http://linuxwiki.de/$1',0,''),
('lojban','https://www.lojban.org/tiki/tiki-index.php?page=$1',0,''),
('lqwiki','http://wiki.linuxquestions.org/wiki/$1',0,''),
('meatball','http://www.usemod.com/cgi-bin/mb.pl?$1',0,''),
('mediawikiwiki','https://www.mediawiki.org/wiki/$1',0,'https://www.mediawiki.org/w/api.php'),
('memoryalpha','http://en.memory-alpha.org/wiki/$1',0,'http://en.memory-alpha.org/api.php'),
('metawiki','http://sunir.org/apps/meta.pl?$1',0,''),
('metawikimedia','https://meta.wikimedia.org/wiki/$1',0,'https://meta.wikimedia.org/w/api.php'),
('mozillawiki','https://wiki.mozilla.org/$1',0,'https://wiki.mozilla.org/api.php'),
('mw','https://www.mediawiki.org/wiki/$1',0,'https://www.mediawiki.org/w/api.php'),
('oeis','https://oeis.org/$1',0,''),
('openwiki','http://openwiki.com/ow.asp?$1',0,''),
('pmid', 'https://www.ncbi.nlm.nih.gov/pubmed/$1?dopt=Abstract',0,''),
('pythoninfo','https://wiki.python.org/moin/$1',0,''),
('rfc','https://tools.ietf.org/html/rfc$1',0,''),
('s23wiki','http://s23.org/wiki/$1',0,'http://s23.org/w/api.php'),
('seattlewireless','http://seattlewireless.net/$1',0,''),
('senseislibrary','https://senseis.xmp.net/?$1',0,''),
('shoutwiki','http://www.shoutwiki.com/wiki/$1',0,'http://www.shoutwiki.com/w/api.php'),
('squeak','http://wiki.squeak.org/squeak/$1',0,''),
('tmbw','http://www.tmbw.net/wiki/$1',0,'http://tmbw.net/wiki/api.php'),
('tmnet','http://www.technomanifestos.net/?$1',0,''),
('theopedia','https://www.theopedia.com/$1',0,''),
('twiki','http://twiki.org/cgi-bin/view/$1',0,''),
('uncyclopedia','https://en.uncyclopedia.co/wiki/$1',0,'https://en.uncyclopedia.co/w/api.php'),
('unreal','https://wiki.beyondunreal.com/$1',0,'https://wiki.beyondunreal.com/w/api.php'),
('usemod','http://www.usemod.com/cgi-bin/wiki.pl?$1',0,''),
('wiki','http://c2.com/cgi/wiki?$1',0,''),
('wikia','http://www.wikia.com/wiki/$1',0,''),
('wikibooks','https://en.wikibooks.org/wiki/$1',0,'https://en.wikibooks.org/w/api.php'),
('wikidata','https://www.wikidata.org/wiki/$1',0,'https://www.wikidata.org/w/api.php'),
('wikif1','http://www.wikif1.org/$1',0,''),
('wikihow','https://www.wikihow.com/$1',0,'https://www.wikihow.com/api.php'),
('wikinfo','http://wikinfo.co/English/index.php/$1',0,''),
('wikimedia','https://foundation.wikimedia.org/wiki/$1',0,'https://foundation.wikimedia.org/w/api.php'),
('wikinews','https://en.wikinews.org/wiki/$1',0,'https://en.wikinews.org/w/api.php'),
('wikipedia','https://en.wikipedia.org/wiki/$1',0,'https://en.wikipedia.org/w/api.php'),
('wikiquote','https://en.wikiquote.org/wiki/$1',0,'https://en.wikiquote.org/w/api.php'),
('wikisource','https://wikisource.org/wiki/$1',0,'https://wikisource.org/w/api.php'),
('wikispecies','https://species.wikimedia.org/wiki/$1',0,'https://species.wikimedia.org/w/api.php'),
('wikiversity','https://en.wikiversity.org/wiki/$1',0,'https://en.wikiversity.org/w/api.php'),
('wikivoyage','https://en.wikivoyage.org/wiki/$1',0,'https://en.wikivoyage.org/w/api.php'),
('wikt','https://en.wiktionary.org/wiki/$1',0,'https://en.wiktionary.org/w/api.php'),
('wiktionary','https://en.wiktionary.org/wiki/$1',0,'https://en.wiktionary.org/w/api.php')
Function: Wikimedia\Rdbms\Database::sourceFile( /var/www/html/mediawiki/maintenance/interwiki.sql )
Error: 1054 Unknown column 'iw_api' in 'field list' (localhost)
Backtrace:
#0 /var/www/html/mediawiki/includes/libs/rdbms/database/Database.php(1556): Wikimedia\Rdbms\Database->getQueryExceptionAndLog(string, integer, string, string)
#1 /var/www/html/mediawiki/includes/libs/rdbms/database/Database.php(1274): Wikimedia\Rdbms\Database->reportQueryError(string, integer, string, string, boolean)
#2 /var/www/html/mediawiki/includes/libs/rdbms/database/Database.php(4430): Wikimedia\Rdbms\Database->query(string, string)
#3 /var/www/html/mediawiki/includes/libs/rdbms/database/Database.php(4365): Wikimedia\Rdbms\Database->sourceStream(resource (closed), NULL, NULL, string, NULL)
#4 /var/www/html/mediawiki/includes/installer/DatabaseUpdater.php(690): Wikimedia\Rdbms\Database->sourceFile(string)
#5 /var/www/html/mediawiki/includes/installer/MysqlUpdater.php(453): DatabaseUpdater->applyPatch(string, boolean, string)
#6 /var/www/html/mediawiki/includes/installer/DatabaseUpdater.php(489): MysqlUpdater->doInterwikiUpdate()
#7 /var/www/html/mediawiki/includes/installer/DatabaseUpdater.php(453): DatabaseUpdater->runUpdates(array, boolean)
#8 /var/www/html/mediawiki/maintenance/update.php(203): DatabaseUpdater->doUpdates(array)
#9 /var/www/html/mediawiki/maintenance/doMaintenance.php(96): UpdateMediaWiki->execute()
#10 /var/www/html/mediawiki/maintenance/update.php(266): require_once(string)
This is the complete message. 213.23.90.238 (talk) 09:49, 5 August 2019 (UTC)
Looks like there's a bug during upgrade from this ancient version of MediaWiki.
You can manually add the missing column yourself running this script: patch-iw_api_and_wikiid.sql
I've created T229857 to track this error. Ciencia Al Poder (talk) 17:08, 5 August 2019 (UTC)
The additions of the two columns in the interwiki table allowed me to apply the update. However another table (valid_tag) seems to be missing (error 1146) which I have not yet found a solution on the forums.
[11f9a0e3243682fd13c095f2] [no req]   Wikimedia\Rdbms\DBQueryError from line 1587 of /var/www/html/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  vt_tag AS `value`  FROM `valid_tag`
Function: PopulateChangeTagDef::setUserDefinedTags
Error: 1146 Table 'xyz_wiki.valid_tag' doesn't exist (localhost)
Any idea regarding this? T. Nordlund (talk) 08:50, 6 August 2019 (UTC)
Looks like you have an outdated extension installed, because that table no longer exists: Manual:Valid_tag_table Ciencia Al Poder (talk) 09:17, 6 August 2019 (UTC)
Much appreciated. Creating the table myself resulted in the update.php being successfully finished. T. Nordlund (talk) 10:15, 6 August 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

who packs packages of MediaWiki for synology NAS?

Synology themselves.
I'm not sure who I have to ask, so I try it here.
For the synology disk Station there is a MediaWiki package that contains V 1.30.
Can someone tell me when a new package will be released?
I want to use the VisualEditor Extension and it reports me that I need Version 1.31 or higher.
Thanks for reading ;-)
Reiner 217.86.241.99 (talk) 14:01, 25 July 2019 (UTC)
Reiner,
I checked with Synology tech. support and it is Synology which maintains the MediaWiki package for Synology NAS. Their recommendation was to register your interest in getting the package updated through the Synology Feature request form: www.synology.com/en-us/form/inquiry/feature
I did do so today, and, as usual, I guess volume is key, so don't hesitate to register one yourself.
Best regards,
Lars IDLLDI (talk) 08:22, 8 November 2019 (UTC)
To start, where exactly to find a MediaWiki package for Synology Disk Station? Malyacko (talk) 15:52, 25 July 2019 (UTC)
In the Disk Station you can find it in the package manager, but at the moment in version 1.30.
Reiner 217.86.241.99 (talk) 01:43, 26 July 2019 (UTC)
As far as I'm aware, Synology does all of that themselves. —TheDJ (Not WMF) (talkcontribs) 08:34, 26 July 2019 (UTC)
the synology support told me (I ask them first) that they have no influence to the update cycle of third-party products. The developer of such products give the update packages to synology and I have to ask the developer when to get an update.
So, we have an support-request-cycle here :) ReinerWolff2 (talk) 09:46, 29 July 2019 (UTC)
synology support answered:
Synology is publisher but not developer of the package.
Please contact the developer (MediaWiki).
So I am back to my question: Where can I get contact to the MediaWiki developers (for the synology diskstation package)? ReinerWolff2 (talk) 12:35, 29 July 2019 (UTC)
Our release cycle is published and we don't provide packages to synology. As to who does, we cannot help you. —TheDJ (Not WMF) (talkcontribs) 14:19, 29 July 2019 (UTC)
Hmm, https://www.synology.com/en-global/dsm/packages/MediaWiki has no indication who made it. Definitely doesn't seem like anyone associated with mediawiki did. As far as I know, no mediawiki developers are associated with any of the mediawiki distro packages except the debian package. Bawolff (talk) 06:49, 2 August 2019 (UTC)
Now that Mediawiki 1.35 is out with bundled VisualEditor support, I'm sure there will be more inquiries about getting this version on Synology. I followed IDLLDI's advice and submitted a request via www.synology.com/en-us/form/inquiry/feature. MikeDarling (talk) 12:58, 9 October 2020 (UTC)
1.35 is available for Docker. Why not just run Docker on your Synology then install the 1.35 docker image as a workaround? 68.107.247.170 (talk) 18:05, 10 December 2020 (UTC)
Great idea, thanks! MikeDarling (talk) 15:23, 14 December 2020 (UTC)

Problems when upgrading from MW 1.29.2 to MW 1.33.0 [Solved]

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


Hi,

when running the upgrade script upgrade.php inside the maitenance folder the following error occurs:

Beginning migration of logging.log_user and logging.log_user_text to logging.log_actor

[d0923ea25688c2ffc826f976] [no req]   Wikimedia\Rdbms\DBQueryError from line 1587 of /var/customers/webs/mgfvlw/wiki/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: INSERT  INTO `actor` (actor_name) VALUES ('')

Function: MigrateActors::addActorsForRows

Error: 1062 Duplicate entry '' for key 'actor_name' (localhost)

Backtrace:

#0 /var/customers/webs/mgfvlw/wiki/includes/libs/rdbms/database/Database.php(1556): Wikimedia\Rdbms\Database->getQueryExceptionAndLog(string, integer, string, string)

#1 /var/customers/webs/mgfvlw/wiki/includes/libs/rdbms/database/Database.php(1274): Wikimedia\Rdbms\Database->reportQueryError(string, integer, string, string, boolean)

#2 /var/customers/webs/mgfvlw/wiki/includes/libs/rdbms/database/Database.php(2149): Wikimedia\Rdbms\Database->query(string, string)

#3 /var/customers/webs/mgfvlw/wiki/maintenance/includes/MigrateActors.php(226): Wikimedia\Rdbms\Database->insert(string, array, string)

#4 /var/customers/webs/mgfvlw/wiki/maintenance/includes/MigrateActors.php(306): MigrateActors->addActorsForRows(Wikimedia\Rdbms\DatabaseMysqli, string, array, array, integer)

#5 /var/customers/webs/mgfvlw/wiki/maintenance/includes/MigrateActors.php(122): MigrateActors->migrate(string, array, string, string, string)

#6 /var/customers/webs/mgfvlw/wiki/maintenance/Maintenance.php(1719): MigrateActors->doDBUpdates()

#7 /var/customers/webs/mgfvlw/wiki/includes/installer/DatabaseUpdater.php(1318): LoggedUpdateMaintenance->execute()

#8 /var/customers/webs/mgfvlw/wiki/includes/installer/DatabaseUpdater.php(489): DatabaseUpdater->migrateActors()

#9 /var/customers/webs/mgfvlw/wiki/includes/installer/DatabaseUpdater.php(453): DatabaseUpdater->runUpdates(array, boolean)

#10 /var/customers/webs/mgfvlw/wiki/maintenance/update.php(203): DatabaseUpdater->doUpdates(array)

#11 /var/customers/webs/mgfvlw/wiki/maintenance/doMaintenance.php(96): UpdateMediaWiki->execute()

#12 /var/customers/webs/mgfvlw/wiki/maintenance/update.php(266): require_once(string)

#13 {main}


The system is Debian 9 with PHP version 7.1.30 and MariaDB 10.1

I searched a lot of pages but nothing really fixed the issue.

Is there anyone who call help me?

Kind regards Michael Micgrote (talk) 19:47, 25 July 2019 (UTC)

Wondering if running maintenance/migrateActors.php and/or maintenance/cleanupUsersWithNoId.php might help, as per Malyacko (talk) 19:54, 25 July 2019 (UTC)
Hi,
maintenance/migrateActors.php hast the same result as above and maintenance/cleanupUsersWithNoId.php does not help either
KR Michael Micgrote (talk) 20:14, 25 July 2019 (UTC)
Hi,
problem solved by deleting an "empty" entry in the actors table: Duplicate entry '' for key 'actor_name' (localhost)
Thanks
Michael Micgrote (talk) 20:35, 25 July 2019 (UTC)
If you have more information about how that entry with a blank actor name did end up in your database, it would be good to bugreport that so the migration script takes that into account. Ciencia Al Poder (talk) 09:11, 26 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Forbidden to access MediaWiki folder on server after migration

Hello,

I just migrated a MediaWiki from GoDaddy to another host (Electric Embers). The media wiki is at policy.bsc.coop which just points to the folder policy on bsc.coop or better said it points to bsc.coop/policy.

After migrating and changing the local setting file to point to the correct host and database I get a 403 forbidden error mention when attempting to access the wiki via policy.bsc.coop or bsc.coop/policy. It says I am forbidden to access /policy/ on this server.

Any help or tips of what to check would be greatly appreciated :) 2607:FB90:30B6:71E2:F420:10F5:7E41:F1FE (talk) 08:22, 26 July 2019 (UTC)

This is a configuration problem of the server.
Either the folder doesn't have read permissions for the web server software to access it, or the web server software is not configured to allow that path to be accessed from the internet. Ciencia Al Poder (talk) 09:09, 26 July 2019 (UTC)

Stop adding <p></p> between div

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


When I type


<div style="text-indent:1em;">example

example

example

example

example

example

</div>


mediawiki will display it as:

<div style="text-indent:1em;">example

<p>example

example

example

example

example

</p>

</div>


Is there a way to stop adding <p></p>? 維基小霸王 (talk) 15:00, 26 July 2019 (UTC)

See $wgUseTidy or $wgTidyConfig. MarkAHershberger(talk) 16:11, 26 July 2019 (UTC)

Why are you typing that?

In wikisyntax, a new line starts a new paragraph, if you don't want that, you should separate your example by spaces instead of newlines e.g.



<div style="text-indent:1em">example example example</div>

Bawolff (talk) 06:43, 2 August 2019 (UTC)
In Wikisource, we input text with a breaks as in the printed book. When displaying the text, there should be no breaks within a paragraph.
I have solved this problem by using a template. It uses Lua to delete break in the text. 維基小霸王 (talk) 12:22, 2 August 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

TRYING TO UPGRADE PHP

Hi team,

I have the following PHP version:

PHP 5.4.16 (cli) (built: Jun 19 2018 13:09:01)


After installing MediaWiki, I saw a message telling that the PHP version was to old and asking for upgrading it.


Well, here the problems began: in RedHat 7 I'm trying to upgrade/replace the PHP version to a v7 ones but now I have even lose the "beautiful" html error page and I'm seeing a text page that begins with:


/** * This is the main web entry point for MediaWiki. * * If you are reading this in your web browser, your server is probably * not configured correctly to run PHP applications! * * See the README, INSTALL, and UPGRADE files for basic setup instructions * and pointers to the online documentation. * * https://www.mediawiki.org/wiki/Special:MyLanguage/MediaWiki


I'm a bit desperate :(


Thank you for your help,


Jesús 195.55.64.11 (talk) 15:51, 26 July 2019 (UTC)

It looks like you need to enable the php module for apache since, without it, it thinks php is just plain text. MarkAHershberger(talk) 15:57, 26 July 2019 (UTC)
Try these instructions. MarkAHershberger(talk) 16:01, 26 July 2019 (UTC)

mobile frontend for vector skin

Can someone please help me get the mobilefront end extension to work on my mediawiki site? 96.23.172.37 (talk) 17:13, 26 July 2019 (UTC)

what problem are you having? MarkAHershberger(talk) 17:46, 26 July 2019 (UTC)
Hey! thanks for replying!
Everytime i install the mobile frontend extention and add the snippet to the local settings.php, the goes to 500 error.
I am using the vector skin, latest versions of mediawiki 96.23.172.37 (talk) 21:00, 26 July 2019 (UTC)
Could you paste the text of your localsettings.php that you are editing. At least the line before and the line after any you have added. If you're comfortable with it, you could even paste your whole LocalSettings.php. MarkAHershberger(talk) 21:24, 26 July 2019 (UTC)
of course! coming right up! 96.23.172.37 (talk) 21:33, 26 July 2019 (UTC)
<?php
# This file was automatically generated by the MediaWiki 1.32.0
# installer. If you make manual changes, please keep track in case you
# need to recreate them later.
#
# See includes/DefaultSettings.php for all configurable settings
# and their default values, but don't forget to make changes in _this_
# file, not there.
#
# Further documentation for configuration settings may be found at:
# https://www.mediawiki.org/wiki/Manual:Configuration_settings
# Protect against web entry
if ( !defined( 'MEDIAWIKI' ) ) {
    exit;
}
## Uncomment this to disable output compression
# $wgDisableOutputCompression = true;
$wgSitename = "CFA Wiki";
$wgMetaNamespace = "CFA_Wiki";
## The URL base path to the directory containing the wiki;
## defaults for all runtime URL paths are based off of this.
## For more information on customizing the URLs
## (like /w/index.php/Page_title to /wiki/Page_title) please see:
## https://www.mediawiki.org/wiki/Manual:Short_URL
$wgScriptPath = "/CFA";
## The protocol and server name to use in fully-qualified URLs
$wgServer = "http://designation.wiki";
## The URL path to static resources (images, scripts, etc.)
$wgResourceBasePath = $wgScriptPath;
## The URL path to the logo.  Make sure you change this from the default,
## or else you'll overwrite your logo when you upgrade!
$wgLogo = "http://designation.wiki/CFA/logos/logo4.6.png";
## UPO means: this is also a user preference option
$wgEnableEmail = true;
$wgEnableUserEmail = true; # UPO
$wgEmergencyContact = "admin@designation.wiki";
$wgPasswordSender = "admin@designation.wiki";
$wgEnotifUserTalk = true; # UPO
$wgEnotifWatchlist = false; # UPO
$wgEmailAuthentication = true;
## Database settings
$wgDBtype = "sqlite";
$wgDBserver = "";
$wgDBname = "cfa_database";
$wgDBuser = "";
$wgDBpassword = "";
# SQLite-specific settings
$wgSQLiteDataDir = ".../data";
$wgObjectCaches[CACHE_DB] = [
    'class' => SqlBagOStuff::class,
    'loggroup' => 'SQLBagOStuff',
    'server' => [
        'type' => 'sqlite',
        'dbname' => 'wikicache',
        'tablePrefix' => '',
        'dbDirectory' => $wgSQLiteDataDir,
        'flags' => 0
    ]
];
$wgLocalisationCacheConf['storeServer'] = [
    'type' => 'sqlite',
    'dbname' => "{$wgDBname}_l10n_cache",
    'tablePrefix' => '',
    'dbDirectory' => $wgSQLiteDataDir,
    'flags' => 0
];
## Shared memory settings
$wgMainCacheType = CACHE_NONE;
$wgMemCachedServers = [];
## To enable image uploads, make sure the 'images' directory
## is writable, then set this to true:
$wgEnableUploads = true;
$wgUseImageMagick = true;
$wgImageMagickConvertCommand = "/usr/bin/convert";
# InstantCommons allows wiki to use images from https://commons.wikimedia.org
$wgUseInstantCommons = false;
# Periodically send a pingback to https://www.mediawiki.org/ with basic data
# about this MediaWiki instance. The Wikimedia Foundation shares this data
# with MediaWiki developers to help guide future development efforts.
$wgPingback = true;
## If you use ImageMagick (or any other shell command) on a
## Linux server, this will need to be set to the name of an
## available UTF-8 locale
$wgShellLocale = "en_US.utf8";
## Set $wgCacheDirectory to a writable directory on the web server
## to make your wiki go slightly faster. The directory should not
## be publically accessible from the web.
#$wgCacheDirectory = "$IP/cache";
# Site language code, should be one of the list in ./languages/data/Names.php
$wgLanguageCode = "en-ca";
$wgSecretKey = "**********";
# Changing this will log out all existing sessions.
$wgAuthenticationTokenVersion = "1";
# Site upgrade key. Must be set to a string (default provided) to turn on the
# web installer while LocalSettings.php is in place
$wgUpgradeKey = "********";
## For attaching licensing metadata to pages, and displaying an
## appropriate copyright notice / icon. GNU Free Documentation
## License and Creative Commons licenses are supported so far.
$wgRightsPage = ""; # Set to the title of a wiki page that describes your license/copyright
$wgRightsUrl = "https://creativecommons.org/licenses/by-sa/4.0/";
$wgRightsText = "Creative Commons Attribution-ShareAlike";
$wgRightsIcon = "$wgResourceBasePath/resources/assets/licenses/cc-by-sa.png";
# Path to the GNU diff3 utility. Used for conflict resolution.
$wgDiff3 = "/usr/bin/diff3";
# The following permissions were set based on your choice in the installer
$wgGroupPermissions['*']['createaccount'] = true;
$wgGroupPermissions['*']['edit'] = true;
## Default skin: you can change the default skin. Use the internal symbolic
## names, ie 'vector', 'monobook':
$wgDefaultSkin = "Vector";
# Enabled skins.
# The following skins were automatically enabled:
wfLoadSkin( 'MonoBook' );
wfLoadSkin( 'Timeless' );
wfLoadSkin( 'Vector' );
wfLoadSkin( 'Metrolook' );
wfLoadSkin( 'Refreshed' );
# Enabled extensions. Most of the extensions are enabled by adding
# wfLoadExtensions('ExtensionName');
# to LocalSettings.php. Check specific extension documentation for more details.
# The following extensions were automatically enabled:
wfLoadExtension( 'ConfirmEdit' );
require_once "$IP/extensions/DynamicArticleList/DynamicArticleList.php";
wfLoadExtension( 'MobileFrontend' );
96.23.172.37 (talk) 21:36, 26 July 2019 (UTC)
any ideas? 96.23.172.37 (talk) 22:11, 26 July 2019 (UTC)
Thanks for pasting it. I was hoping for a syntax error or something but I don't see one.
What does your error log say when you get the 500 error code? MarkAHershberger(talk) 23:32, 26 July 2019 (UTC)
is it normal that i dont see mobile frontend under installed extensions in special:version? 96.23.172.37 (talk) 00:52, 27 July 2019 (UTC)
ok i fixed that up, and now i see this error 96.23.172.37 (talk) 01:05, 27 July 2019 (UTC)
Is the problem resolved? MarkAHershberger(talk) 15:36, 27 July 2019 (UTC)

Text verbergen / Hide Text

Hallo Zusammen,

kann man einen Text so lange in einem Artikel verbergen, bis man angemeldet ist.

Ich möchte einen längeren Eintrag bei mir im WIKI machen, aber spezielle Teile des Textes sollen nur angezeigt werden, wenn man angemeldet ist. SIsco86 (talk) 10:50, 27 July 2019 (UTC)

Why? Please explain which underlying problem you want to solve by your proposed "solution". Malyacko (talk) 11:13, 27 July 2019 (UTC)
Ich möchte in einem Artikel Texte verbergen, die nur für angemeldete Benutzer zugänglich sein sollen.
Jeder soll die "allgemeinen Texte" sehen. Die angemeldeten Benutzer etwas mehr. 2.247.249.68 (talk) 14:45, 27 July 2019 (UTC)
MediaWiki isn't really built for that sort of content handling.
Still, you could probably hack something together with some JS and templates. Maybe.
But, like I said, you would have to do this yourself. MarkAHershberger(talk) 15:44, 27 July 2019 (UTC)

Error during upgrading to MediaWiki 1.32.0

Hi. I want to upgrade to MediaWiki 1.32.0 but during the upgrade process I get this error (see below). It occurs during the mw-config-procces at the second step (Existing wiki). What can I do to correct it?

Fatal error: Uncaught Error: Call to undefined method Article::getContent() in /www-folder/public_html/extensions/Emoticons/Emoticons.php:65 Stack trace:

#0 /www-folder/public_html/includes/Hooks.php(174): fnEmoticons(Object(Parser), 'Internal error ...', Object(StripState))

#1 /www-folder/public_html/includes/Hooks.php(202): Hooks::callHook('ParserAfterStri...', Array, Array, NULL)

#2 /www-folder/public_html/includes/parser/Parser.php(735): Hooks::run('ParserAfterStri...', Array)

#3 /www-folder/public_html/includes/parser/Parser.php(4800): Parser->preprocess('Internal error ...', NULL, Object(ParserOptions))

#4 /www-folder/public_html/includes/cache/MessageCache.php(1174): Parser->transformMsg('Internal error ...', Object(ParserOptions), NULL)

#5 /www-folder/public_html/includes/Message.php(1282): MessageCache->tra in /www-folder/public_html/extensions/Emoticons/Emoticons.php on line 65


MySQL: Serverversion: 5.5.52-MariaDB-cll-lve. PHP 7.2.9. Degn (talk) 12:05, 27 July 2019 (UTC)

Disable your extensions, specifically Extension:Emoticons, and then try to upgrade again. The extension probably needs to be upgraded before it can be used with the newer MediaWiki version. AhmadF.Cheema (talk) 14:15, 27 July 2019 (UTC)

Missing entries in Special:Categories

Special:Categories shows the correct number of pages but when clicking on the category name (Category:something) there is only one page listed.

I tried to run several maintenance jobs but none solved the problem.

Mediawiki Version: 1.31.3 79.246.209.66 (talk) 18:47, 27 July 2019 (UTC)

Categorization is done in background jobs. See Manual:Job queue.
Try the following:
  1. Edit and save one of the pages that don't appear in the category (but should)
  2. run maintenance/runJobs.php from the command line
  3. See if the category page now displays the page on that category. You can also try purging the category page to discard caching problems.
If that doesn't work, this means the categorization job is failing. This is often caused by buggy or incompatible extensions. Try to disable all extensions and try the steps above again. Ciencia Al Poder (talk) 09:27, 29 July 2019 (UTC)
Thank you for answering.
  1. and 2. I tried before with no success for updating category pages. But 3. does it!
So it is a cache problem which makes sense as the first entry is not in the cache and after that the cache prevents getting an updated page. Now having understood this leads to the question how to avoid it?
Is this a configuration problem of the cache or what else. The problem comes at each adding to a category. What to do? Preventing that category pages get cached? It would be great if you had another advice. 79.246.204.170 (talk) 17:19, 30 July 2019 (UTC)
Do you have caching enabled? What type of cache? A file cache or front-end caching like varnish/squid?
Also ensure the problem is not the browser cache (i.e.: try to open the category page using private browsing and see if it displays it correctly) Ciencia Al Poder (talk) 17:25, 30 July 2019 (UTC)
It's not the browser cache.
memcached is enabled:
## Shared memory settings
$wgMainCacheType = CACHE_MEMCACHED;
$wgMemCachedServers = [ 'x.x.x.x:11211' ];
$wgParserCacheType = CACHE_MEMCACHED; # optional
$wgMessageCacheType = CACHE_MEMCACHED; # optional
$wgSessionsInObjectCache = true; # optional
$wgSessionCacheType = CACHE_MEMCACHED; # optional
# Proxies
$wgSquidServers = array();
$wgSquidServers[] = "y.y.y.y";
$wgUseSquid = false; 79.246.204.170 (talk) 18:16, 30 July 2019 (UTC)
Have you tried running recountCategories.php Bawolff (talk) 06:40, 2 August 2019 (UTC)
I had an instance of categorization failing (the runJobs.php script skipped one of the pages being categorized, without any reason), on MediaWiki 1.32, so this can very well be a bug, but I don't think it can be reproduced consistently. Ciencia Al Poder (talk) 09:33, 2 August 2019 (UTC)
I created a new wiki page containing 2 category links.
That increased the counter of category "A" from 2 to 3 and that of category "B" from 164 to 165.
The new page was not listed in both categories when trying to look them up.
Manually running php maintenance/showJobs.php did output "2".
After waiting cron did run the scheduled runJobs.php the output changed to "0" but the page did not show up in neither "A" nor "B" category.
I did run the recountCategories.php with each -mode options and I did run refreshLinks.php which had no effect.
Only purging manually each category page by appending "&action=purge" to the URL made finally appear the new page.
As this procedure should not be necessary by design after adding a page to a wiki please forward this report for a code review.

217.86.18.230 (talk) 14:14, 4 August 2019 (UTC)
The problem seems to be the same when a page was removed from a category by deleting the category link. Also in this case only a manual "&action=purge" finally does the job. 217.86.18.230 (talk) 14:26, 4 August 2019 (UTC)

how can I make my wiki accessible from the outside by others?

hey guys extreme beginner here and I have successfully have created my own wiki.

i used bitnami to make my wiki by the way.


i want my wiki to be accessible by others. the problem is that i don't know how. for example, my wiki link is like 127.0.0.1:80/mediawiki, and I want it somehow to accessible by others


how can I make it accessible by others? i appreciate the help. El33tbr0 (talk) 23:24, 27 July 2019 (UTC)

See Project:Support desk/Flow/2017/03#h-(Confused_beginner)_Accessing_my_wiki_from_anywhere-2017-03-12T04:10:00.000Z. AhmadF.Cheema (talk) 02:07, 28 July 2019 (UTC)

Fatal exception of type "Wikimedia\Rdbms\DBQueryError"

[dd0e3c529fbb02ddab4cce30] 2019-07-28 00:14:55: Fatal exception of type "Wikimedia\Rdbms\DBQueryError" came back after I tried to save a PollNY to my wiki https://nwmarches.miraheze.org/wiki/Special:CreatePoll

I've tried 2 polls, one had an image, the other did not. BradHenderson (talk) 00:22, 28 July 2019 (UTC)

For Miraheze related queries, see their Community noticeboard. AhmadF.Cheema (talk) 02:10, 28 July 2019 (UTC)

Help with age template

Wikipedia has a template that calculates a person's age: https://en.wikipedia.org/wiki/Template:Birth_date_and_age

I'd like to create the same template, but I'm not sure how to get it to work. I got this source code from the Wikipedia template:

 <includeonly>{{{{{♥|safesubst:}}}#invoke:age|birth_date_and_age}}</includeonly><noinclude>{{documentation}}</noinclude> 

I created my own template with the same name and put the above code in the page. But this doesn't work, when I try to use it, I get:

 {{safesubst:#invoke:age|birth_date_and_age}}  
Scott216 (talk) 16:21, 28 July 2019 (UTC)
Have you installed Extension:Scribunto? This template relies on lua modules w:module:age, etc. that requires this extension. You should install this extension and import these required modules. 94rain Talk 16:25, 28 July 2019 (UTC)
Good Morning,
If I use some information that I find on PUBMED about medicine (https://www.ncbi.nlm.nih.gov), some abstracts or some studies "FREE PMC ARTICLES", do I need a written authorization?
Is it enough a citation with author, title and journal?
Many thanks 188.152.145.179 (talk) 19:59, 28 July 2019 (UTC)
It sounds like you're asking how to provide attribution for work you are doing on wikipedia.
Since this is related to PUBMED, you can probably find help in WikiProject Medicine. MarkAHershberger(talk) 21:59, 28 July 2019 (UTC)
Hi, I don't see how this question is related to the MediaWiki software? If you have a question about licenses of content on a website, you have to ask on that website? Malyacko (talk) 21:05, 28 July 2019 (UTC)

Unable to install MediaWiki. A database query error has occurred. Did you forget to run your application's database schema updater after upgrading?

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


Brief description
Unable to install MediaWiki
I have tried to remove and reinstall mysql.
Seems like database is not even created.
Trying to install MediaWiki 1.33.0

My environment

OS
Description
Ubuntu 18.04.2 LTS
Release
18.04
Codename
bionic
MYSQL
mysql: Ver 14.14 Distrib 5.7.27, for Linux (x86_64) using EditLine wrapper
PHP
PHP 7.3.7-2+ubuntu18.04.1+deb.sury.org+1 (cli) (built: Jul 25 2019 11:44:59) ( NTS )

Details:

Detail description
On the installation part of installer the following message:
[4588351c4de48e512c837559] /mw-config/index.php?page=Install Wikimedia\Rdbms\DBQueryError from line 1587 of /var/www/html/mwiki/mediawiki-1.33.0/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?
details
Query: CREATE TABLE user (
user_id int unsigned NOT NULL PRIMARY KEY AUTO_INCREMENT,
user_name varchar(255) binary NOT NULL default '',
user_real_name varchar(255) binary NOT NULL default '',
user_password tinyblob NOT NULL,
user_newpassword tinyblob NOT NULL,
user_newpass_time binary(14),
user_email tinytext NOT NULL,
user_touched binary(14) NOT NULL default '',
user_token binary(32) NOT NULL default '',
user_email_authenticated binary(14),
user_email_token binary(32),
user_email_token_expires binary(14),
user_registration binary(14),
user_editcount int,
user_password_expires varbinary(14) DEFAULT NULL
) ENGINE=InnoDB, DEFAULT CHARSET=binary
Function: Wikimedia\Rdbms\Database::sourceFile( /var/www/html/mwiki/mediawiki-1.33.0/maintenance/tables.sql )
Error: 1142 CREATE command denied to user 'wikiad'@'localhost' for table 'user' (localhost)
Backtrace:
#0 /var/www/html/mwiki/mediawiki-1.33.0/includes/libs/rdbms/database/Database.php(1556): Wikimedia\Rdbms\Database->getQueryExceptionAndLog(string, integer, string, string)
#1 /var/www/html/mwiki/mediawiki-1.33.0/includes/libs/rdbms/database/Database.php(1274): Wikimedia\Rdbms\Database->reportQueryError(string, integer, string, string, boolean)
#2 /var/www/html/mwiki/mediawiki-1.33.0/includes/libs/rdbms/database/Database.php(4430): Wikimedia\Rdbms\Database->query(string, string)
#3 /var/www/html/mwiki/mediawiki-1.33.0/includes/libs/rdbms/database/Database.php(4365): Wikimedia\Rdbms\Database->sourceStream(resource (closed), NULL, NULL, string, NULL)
#4 /var/www/html/mwiki/mediawiki-1.33.0/includes/installer/DatabaseInstaller.php(227): Wikimedia\Rdbms\Database->sourceFile(string)
#5 /var/www/html/mwiki/mediawiki-1.33.0/includes/installer/DatabaseInstaller.php(250): DatabaseInstaller->stepApplySourceFile(string, string, boolean)
#6 /var/www/html/mwiki/mediawiki-1.33.0/includes/installer/Installer.php(1596): DatabaseInstaller->createTables(MysqlInstaller)
#7 /var/www/html/mwiki/mediawiki-1.33.0/includes/installer/WebInstallerInstall.php(44): Installer->performInstallation(array, array)
#8 /var/www/html/mwiki/mediawiki-1.33.0/includes/installer/WebInstaller.php(264): WebInstallerInstall->execute()
#9 /var/www/html/mwiki/mediawiki-1.33.0/mw-config/index.php(80): WebInstaller->execute(array)
#10 /var/www/html/mwiki/mediawiki-1.33.0/mw-config/index.php(38): wfInstallerMain()
#11 {main}
Usek2 (talk) 23:24, 28 July 2019 (UTC)
The backtrace contains this error: "CREATE command denied to user 'wikiad'@'localhost' for table 'user'".
You probably need to use the root mysql user to install MediaWiki and use the wikiad user to run the wiki. MarkAHershberger(talk) 23:55, 28 July 2019 (UTC)
And that solved the problem. :) I guess MediaWiki installer suggested that user by automatically filling in the field for mysql username which I have igonred. Usek2 (talk) 08:06, 29 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

window.RLQ=window.RLQ failed in 1.33

Project:Support desk/Flow/2016/10#h-jQuery_is_not_defined_when_upgrade_from_1.20_to_1.25-2016-10-19T09:46:00.000Z


I tried the recommendation when upgrade from 1.20 to 1.25 by using

(window.RLQ=window.RLQ||[]).push(function(){
$(function() { console.log("test") });
});


but it failed when I upgraded to 1.33, I got jQuery is not defined again Chan15tw (talk) 09:42, 29 July 2019 (UTC)

Are you specifying your RL dependencies in your extension.json? MarkAHershberger(talk) 16:04, 29 July 2019 (UTC)
https://www.mediawiki.org/wiki/Extension:CustomNavBlocks I use this extension, it doesn't have that file, I just put JavaScript code in the CustomNavBlocks.php, and it work perfectly on 1.27 Chan15tw (talk) 07:37, 30 July 2019 (UTC)
The problem you're having is that ResourceLoader helps manage dependencies between javascript. See mw.loader.using to see how you can specify a dependency in js.
You might also try this fork which updates the extension for MW 1.32+. MarkAHershberger(talk) 15:06, 30 July 2019 (UTC)

LdapAuth problems

Running on Ubuntu 19.04. UFW is disabled, iptables is set to accept all, and selinux is disabled on the webserver. Domain Controller isn't blocking LDAP connections because our entire environment is set to use LDAP. I can ping the DC from the webserver and vice versa. I am having trouble binding to the LDAP server with ldapsearch. I can search the naming contexts on the server so it's obviously talking to the LDAP server just won't bind because it won't accept the password for my users account. So that could be my issue LDAP server may be blocking it. When I try to bind to the LDAP server this is the error I get:

$ ldapsearch -H ldap://coruscant.snrt.io -x -D "cn=Administrator,cn=Users,dc=snrt,dc=io" -W
Enter LDAP Password:
# extended LDIF
#
# LDAPv3
# base <> (default) with scope subtree
# filter: (objectclass=*)
# requesting: ALL
#
# search result
search: 2
result: 32 No such object
text: 0000208D: NameErr: DSID-031001EE, problem 2001 (NO_OBJECT), data 0, best
match of:
''
# numResponses: 1


Checked the firewall running on the DC that is also the LDAP/AD server and all the LDAP ports:389, 636 are open to any connection.

I completely turned off the firewall on the LDAP/AD server and I still could not establish a connection from mediawiki. I assume something on the Ubuntu box is blocking it. Tmhoskins (talk) 12:20, 29 July 2019 (UTC)

This sounds like a problem that you need to ask some LDAP specialists about.
All I can say is that I would check to see what was logged on the AD server when you tried to connect. MarkAHershberger(talk) 15:47, 29 July 2019 (UTC)
The AD server doesn't register errors because there is something wrong with the LocalSettings.php. I am getting errors on the webserver everytime I try to log in to the wiki with an AD account.
Errors:
PHP Warning:  Illegal string offset 'SNRT.IO' in /var/www/html/SNRTwiki/extensions/LdapAuth/src/Auth/PrimaryAuthenticationProvider.php on line 372, referer: http://snrtwiki.snrt.io/index.php?title=Special:UserLogin&returnto=Main+Page&returntoquery=
PHP Warning:  Invalid argument supplied for foreach() in /var/www/html/SNRTwiki/extensions/LdapAuth/src/Auth/PrimaryAuthenticationProvider.php on line 388, referer: http://snrtwiki.snrt.io/index.php?title=Special:UserLogin&returnto=Main+Page&returntoquery=
Please Advise Tmhoskins (talk) 12:30, 30 July 2019 (UTC)
The AD server doesn't register errors because there is something wrong with the LocalSettings.php.
Right, but you said ldapsearch wasn't working either and that has nothing to do with the LocalSettings.php. Until, ldapsearch works there isn't anything that we can offer that will help you get MW with LDAP to work. MarkAHershberger(talk) 14:49, 30 July 2019 (UTC)

Jobqueue not working on upgrade to 1.31

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


I moved and upgraded from MW-1.23. Most things are working fine but there are hard-to-track internal errors that appear on some pages. They look like (PageName substituted):
[e4ae3e6c214d28df035bfe14] /index.php/MWiki:G2017A_J1.3_Linearit%C3%A4t/20180116P_Linearit%C3%A4t,_Geraden   TypeError from line 47 of /var/www/html/mwiki/includes/jobqueue/jobs/RefreshLinksJob.php: Argument 2 passed to RefreshLinksJob::__construct() must be of the type array, string given, called in /var/www/html/mwiki/includes/jobqueue/Job.php on line 83<
   Backtrace:
   #0 /var/www/html/mwiki/includes/jobqueue/Job.php(83): RefreshLinksJob->__construct(Title, string)
   #1 /var/www/html/mwiki/includes/jobqueue/JobQueueDB.php(303): Job::factory(string, Title, string, string)
   #2 /var/www/html/mwiki/includes/jobqueue/JobQueue.php(372): JobQueueDB->doPop()
   #3 /var/www/html/mwiki/includes/jobqueue/JobQueueGroup.php(269): JobQueue->pop()
   #4 /var/www/html/mwiki/includes/jobqueue/JobRunner.php(167): JobQueueGroup->pop(integer, integer, array)
   #5 /var/www/html/mwiki/includes/MediaWiki.php(1002): JobRunner->run(array)
   #6 /var/www/html/mwiki/includes/MediaWiki.php(988): MediaWiki->triggerSyncJobs(integer, MediaWiki\Logger\LegacyLogger)
   #7 /var/www/html/mwiki/includes/MediaWiki.php(912): MediaWiki->triggerJobs()
   #8 /var/www/html/mwiki/includes/MediaWiki.php(727): MediaWiki->restInPeace(string, boolean)
   #9 /var/www/html/mwiki/includes/MediaWiki.php(750): MediaWiki->{closure}()
   #10 /var/www/html/mwiki/includes/MediaWiki.php(557): MediaWiki->doPostOutputShutdown(string)
   #11 /var/www/html/mwiki/index.php(42): MediaWiki->run()
   #12 {main}
This seems to be related to the job queue. Indeed, php maintenance/showJobs.php yields 3801 and php maintenance/runJobs.php --maxjobs 100 halts on practically the same error as above:
[a92ddaa8c4248dd5e9bff9a2] [no req]   TypeError from line 47 of /var/www/html/mwiki/includes/jobqueue/jobs/RefreshLinksJob.php: Argument 2 passed to RefreshLinksJob::__construct() must be of the type array, string given, called in /var/www/html/mwiki/includes/jobqueue/Job.php on line 83
   Backtrace:
   #0 /var/www/html/mwiki/includes/jobqueue/Job.php(83): RefreshLinksJob->__construct(Title, string)
   #1 /var/www/html/mwiki/includes/jobqueue/JobQueueDB.php(303): Job::factory(string, Title, string, string)
   #2 /var/www/html/mwiki/includes/jobqueue/JobQueue.php(372): JobQueueDB->doPop()
   #3 /var/www/html/mwiki/includes/jobqueue/JobQueueGroup.php(269): JobQueue->pop()
   #4 /var/www/html/mwiki/includes/jobqueue/JobRunner.php(167): JobQueueGroup->pop(integer, integer, array)
   #5 /var/www/html/mwiki/maintenance/runJobs.php(89): JobRunner->run(array)
   #6 /var/www/html/mwiki/maintenance/doMaintenance.php(94): RunJobs->execute()
   #7 /var/www/html/mwiki/maintenance/runJobs.php(122): require_once(string)
   #8 {main}
I have seen a similar issue in Project:Support desk/Flow/2017/01#h-Recent_changes_stopped_working_after_installation_of_1.28.0-2017-01-07T00:00:00.000Z as well as https://phabricator.wikimedia.org/T201541 but that did not help me any further. I am at wits' end and would be very grateful for some help. Thanks in advance! Sm8ps (talk) 12:44, 29 July 2019 (UTC)
It looks like some incorrect data has ended up in your job queue. On my sqlite-based install, the following would show me what entries are incorrect:
echo "select job_params from job where substr(job_params, 0, 2) != 'a';" | php maintenance/sql.php
Something similar should work for you. Do you see any results? If you need me to update for MySQL, let me know. MarkAHershberger(talk) 14:23, 29 July 2019 (UTC)
Indeed, my installation uses MySQL and I do not see how to adapt these commands. Sm8ps (talk) 14:31, 29 July 2019 (UTC)
I just checked the documentation and the syntax for mysql is the same.
What do you get if you run the above command on the command line while in the mediawiki directory? MarkAHershberger(talk) 14:58, 29 July 2019 (UTC)
/var/www/html/mwiki$ echo "select job_params from job where substr(job_params, 0, 2) != 'a';" | sudo -u www-data php maintenance/sql.php Wikimedia\Rdbms\DBQueryError: A database query error has occurred. Did you forget to run your application's database schema updater after upgrading? Query: select job_params from job where substr(job_params, 0, 2) != 'a' Function: Wikimedia\Rdbms\Database::query Error: 1146 Table 'mwiki.job' doesn't exist (localhost) in /var/www/html/mwiki/includes/libs/rdbms/database/Database.php:1457 Stack trace: #0 /var/www/html/mwiki/includes/libs/rdbms/database/Database.php(1427): Wikimedia\Rdbms\Database->makeQueryException('Table 'mwiki.jo...', 1146, 'select job_para...', 'Wikimedia\\Rdbms...') #1 /var/www/html/mwiki/includes/libs/rdbms/database/Database.php(1200): Wikimedia\Rdbms\Database->reportQueryError('Table 'mwiki.jo...', 1146, 'select job_para...', 'Wikimedia\\Rdbms...', false) #2 /var/www/html/mwiki/maintenance/sql.php(160): Wikimedia\Rdbms\Database->query('select job_para...') #3 /var/www/html/mwiki/maintenance/sql.php(151): MwSql->sqlDoQuery(Object(Wikimedia\Rdbms\DatabaseMysqli), 'select job_para...', true) #4 /var/www/html/mwiki/maintenance/doMaintenance.php(94): MwSql->execute() #5 /var/www/html/mwiki/maintenance/sql.php(205): require_once('/var/www/html/m...') #6 {main}
I have successfully run maintenance/update.php. Sm8ps (talk) 15:12, 29 July 2019 (UTC)
are you using a db prefix? It looks like you might be and that could cause this error. MarkAHershberger(talk) 15:20, 29 July 2019 (UTC)
In LocalSettings.php, I have
$wgDBprefix = "mwiki"; Sm8ps (talk) 15:21, 29 July 2019 (UTC)
Could you try:
echo "select job_params from mwikijob where substr(job_params, 0, 2) != 'a';" | sudo -u www-data php maintenance/sql.php
(There is currently a bug on MW 1.33 that will prevent you from upgrading since your prefix does not end with '_', btw. It should be fixed soon.) MarkAHershberger(talk) 15:27, 29 July 2019 (UTC)
I see the need of a prefix ending in '_' now. This was my very first Mediawiki installation dating from 1.19 and I had no experience whatsoever with databases.
The command outputs 16181 lines, the first 7468 of which are repetitions of
stdClass Object
(
[job_params] => s:0:"";
)
The remainder contains 36 blocks like
 stdClass Object
(
[job_params] => a:4:{s:5:"table";s:13:"templatelinks";s:9:"recursive";b:1;s:16:"rootJobSignature";s:40:"d98b41a87a8345e672bde60fc4158b54330327c4";s:16:"rootJobTimestamp";s:14:"201   7471 50730100553";}
)
1547 blocks like
stdClass Object
(
[job_params] => a:4:{s:5:"table";s:10:"imagelinks";s:9:"recursive";b:1;s:16:"rootJobSignature";s:40:"40241d880f9c648cef0aac211fde09c23ba7bf9d";s:16:"rootJobTimestamp";s:14:"20150730100601";}
)
and 593 blocks like
stdClass Object
(
[job_params] => a:3:{s:5:"pages";a:1:{i:10189;a:2:{i:0;i:1;i:1;s:32:"Konzepte_der_Netzwerktechnologie";}}s:16:"rootJobSignature";s:40:"2edae4fe717bb23daf117473eb17f24447eaa3d9";s:16:"rootJobTimestamp";s:14:"20190611103037";}) Sm8ps (talk) 15:42, 29 July 2019 (UTC)
The rows that start with s: need to be deleted as they are causing the problem.
I was working with the sqlite syntax when I suggested that snippet and it seems to have a significant difference. Or maybe I'm misunderstanding something.
In any case, could you try the following:
echo "select count(*) from mwikijob where substr(job_params, 0, 2) = ' s';" | sudo -u www-data php maintenance/sql.php
and then
echo "select count(*) from mwikijob where substr(job_params, 0, 2) = 's:';" | sudo -u www-data php maintenance/sql.php
Which one of the above returns results? MarkAHershberger(talk) 15:56, 29 July 2019 (UTC)
They both give the same answer but that probably is not what you were looking for?
/var/www/html/mwiki$ echo "select count(*) from mwikijob where substr(job_params, 0, 2) = ' s';" | sudo -u www-data php maintenance/sql.php
 stdClass Object
 (
     [count(*)] => 0
 )
/var/www/html/mwiki$ echo "select count(*) from mwikijob where substr(job_params, 0, 2) = 's:';" | sudo -u www-data php maintenance/sql.php</code>
 stdClass Object
 (
     [count(*)] => 0
 )
Sm8ps (talk) 16:01, 29 July 2019 (UTC)
I just recalled that this is MariaDB but the SQL syntax should not differ from MySQL as far as I know, right? Sm8ps (talk) 16:04, 29 July 2019 (UTC)
Right, they should be the same.
How about this:
echo "select count(*) from mwikijob where job_params = 's:0:\"\";';" | sudo -u www-data php maintenance/sql.php
MarkAHershberger(talk) 16:08, 29 July 2019 (UTC)
Right on!
/var/www/html/mwiki$ echo "select count(*) from mwikijob where job_params = 's:0:\"\";';" | sudo -u www-data php maintenance/sql.php
   stdClass Object
   (
       [count(*)] => 1867
   )
This figure also corresponds to the 7468 (=1867 x 4) lines from above. Sm8ps (talk) 16:14, 29 July 2019 (UTC)
oh, good.
So, run
echo "delete from mwikijob where job_params = 's:0:\"\";';" | sudo -u www-data php maintenance/sql.php
and then try running the job queue again. MarkAHershberger(talk) 16:16, 29 July 2019 (UTC)
HOORAY, it is working! showjobs.php is down to zero now.
I have been so worried about this because this error would have been totally unfixable for myself. Many, many thanks MarkAHershberger! Is there a way to physically thank you for your time and effort?
Do you know of an easy way to fix the inappropriate database prefix? Sm8ps (talk) 16:28, 29 July 2019 (UTC)
Don't worry about the prefix as that bit is being removed and your prefix will work in future MediaWiki. MarkAHershberger(talk) 16:38, 29 July 2019 (UTC)
ok, I got ahold of actual mariadb-backed mediawiki and have a working query:
<syntaxhighlight lang='text'>

echo "select count(*) from mwikijob where substr(job_params, 1,1) = 's';" | sudo -u www-data php maintenance/sql.php MarkAHershberger(talk) 16:14, 29 July 2019 (UTC)

Please disregard the title of the above post! I had taken it from Project:Support desk/Flow/2017/01#h-Recent_changes_stopped_working_after_installation_of_1.28.0-2017-01-07T00:00:00.000Z as the errors looked the same. The special page Recent Changes does indeed work. I had been misguided by the comparison with MW-1.23 where the magic word numberofviews appears in the footer which is missing in MW-1.31 because it has been removed. Sm8ps (talk) 13:19, 29 July 2019 (UTC)
I've updated the title. Please edit it if it is incorrect. MarkAHershberger(talk) 14:21, 29 July 2019 (UTC)
You should always clear any pending jobs (by running runJobs.php) before performing an upgrade
https://www.mediawiki.org/wiki/Manual:Upgrading#Clear_pending_jobs Ciencia Al Poder (talk) 09:37, 30 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Unable to use profiling

MediaWiki: 1.33.0

PHP: 7.3.6

MySQL: 8.0.16


Hi! I have recently installed MediaWiki in Azure using Bitnami's MediaWiki stack. After adding a handful of pages, both saving and loading pages is quite slow (20-30s saving, 5-10s loading). I figured I should do some profiling before asking for help, but unfortunately I can't get that to work either.

I followed the instructions on Manual:Profiling and was able to install XHProf. At least running php -m on the server will now have "xhprof" in the list.

Then I created "StartProfiler.php" in the main folder (same as LocalSettings.php) and added

<?php

$wgProfiler['class'] = 'ProfilerXhprof';

$wgProfiler['output'] = array( 'ProfilerOutputText' );

$wgProfiler['visible'] = true;

If I understand correctly, this should display profiling information somewhere on the webpage, but this does not happen. After digging some more, I learned that the StartProfiler.php file is apparently deprecated, and that $wgProfiler settings should go in LocalSettings.php instead. I tried this as well, but then the webserver stopped responding, and would not even output a debug log.

Does anyone know what could be wrong here? Thanks! 85.19.158.33 (talk) 14:13, 29 July 2019 (UTC)

You are using php 7, so you should be using tideways, not xhprof MarkAHershberger(talk) 21:37, 17 December 2019 (UTC)

Cant finish the instllation of MediaWiki 1.33.0

Hello, this is my first Mediawiki and im trying to make it work on my page, but when i try to install it this Error appears:

[0ba054d6ed0f8fba8311fae8] /mw-config/index.php?page=Install Wikimedia\Rdbms\DBQueryError from line 1587 of /users/sredel/www/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: CREATE DATABASE `sredel`CHARACTER SET utf8
Function: MysqlInstaller::setupDatabase
Error: 1044 Access denied for user 'sredel_1'@'localhost' to database 'sredel' (localhost)
Backtrace:
#0 .../includes/libs/rdbms/database/Database.php(1556): Wikimedia\Rdbms\Database->getQueryExceptionAndLog(string, integer, string, string)
#1 .../includes/libs/rdbms/database/Database.php(1274): Wikimedia\Rdbms\Database->reportQueryError(string, integer, string, string, boolean)
#2 .../includes/installer/MysqlInstaller.php(487): Wikimedia\Rdbms\Database->query(string, string)
#3 .../includes/installer/Installer.php(1596): MysqlInstaller->setupDatabase(MysqlInstaller)
#4 .../includes/installer/WebInstallerInstall.php(44): Installer->performInstallation(array, array)
#5 .../includes/installer/WebInstaller.php(264): WebInstallerInstall->execute()
#6 .../mw-config/index.php(80): WebInstaller->execute(array)
#7 .../mw-config/index.php(38): wfInstallerMain()
#8 {main}
2.247.241.237 (talk) 17:08, 29 July 2019 (UTC)
The problem is that the user you are trying to use does not have the proper permissions: Access denied for user 'sredel_1'@'localhost'.
Either fix the permissions or retry with root. MarkAHershberger(talk) 18:14, 29 July 2019 (UTC)
What do you mean with fix the permissions or retry with root. Im sry, but I really am a rookie with this topic.
Thanks for the reply anyway! 2.247.241.237 (talk) 18:23, 29 July 2019 (UTC)
Do you control this DB? Did you install MySQL? Then you must have set up a root account at sometime for it. Use that.
If you didn't set up MySQL, you'll have to talk to the person who did. MarkAHershberger(talk) 18:41, 29 July 2019 (UTC)

Page Move

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


When we are moving page of "AX: DumpTSGLandingPage" to another page with new title of "AX: Dump Analysis TSG Landing Page", the following error always blocks us. The title is not same, why we got this error?


You do not have permission to move this page, for the following reasons:

  • Source and destination titles are the same; cannot move a page over itself.
  • A page of that name already exists, or the name you have chosen is not valid. Please choose another name. 2001:4898:80E8:F:7168:F576:337C:28E (talk) 20:02, 29 July 2019 (UTC)
because the search engine doesn't abstract the keyword from the title, so title likes this "AX: DumpTSGLandingPage" is no way to be search-able. 2001:4898:80E8:F:7168:F576:337C:28E (talk) 20:05, 29 July 2019 (UTC)
What version are you on?
I'm not sure why you're seeing this issue right off but I would suggest trying to rename to an intermediate page first, deleting the old page, and then moving the page to the preferred name.
If that works, then you can recreate the old page with a redirect to the new page. MarkAHershberger(talk) 20:54, 29 July 2019 (UTC)
we had moved this page once, not sure if this is reason. Is the redirected page name not valid name? 2001:4898:80E8:F:7168:F576:337C:28E (talk) 21:16, 29 July 2019 (UTC)
it works now, don't know why :) 2001:4898:80E8:F:7168:F576:337C:28E (talk) 21:25, 29 July 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Move from MariaDB to MSSQL ?

After weeks of creating a wiki on my virtuall machine locally i now get the information that the virtuall machine i will get from the company will have MSSQL installed instead of MariaDB (which i use right now)


surely i dont want to have the hassle of importing everything again so i was wondering what the easiest way would be to dump my database so far into the MSSQL database and make my mediawiki work on the new machine 62.143.147.133 (talk) 06:22, 30 July 2019 (UTC)

Be aware that MSSQL support is only experimental (Manual:Microsoft_SQL_Server). In general I believe using mysqldump to create a SQL file and then reimporting it into MSSQL using the tools provided by Microsoft should work best. Maybe this can help: https://dba.stackexchange.com/questions/39462/importing-mysql-dump-to-sql-server-2012 Osnard (talk) 06:51, 30 July 2019 (UTC)
yeah i am well aware that mssql support is experimental...but we gotta roll with that at first...if it makes problems i can still try to install mysql or mariadb myself (its a management issue) 62.143.147.133 (talk) 09:09, 30 July 2019 (UTC)
thanks by the way 62.143.147.133 (talk) 09:09, 30 July 2019 (UTC)
In the event you do encounter bugs with MSSQL support, don't hesitate to file bugs (I believe that there are people out there using MSSQL, so i think it does work, it just doesn't get a lot of testing.) Bawolff (talk) 06:38, 2 August 2019 (UTC)

Creating Wiki Accounts from List

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


Hi there,

I would like to create around 200 accounts for my wiki page with specified emailadresses as logins and all belonging to one user group. Is there a posibility to do that in an automated way. For example with a list that I create beforehand? SebastianKazan (talk) 06:48, 30 July 2019 (UTC)

Can probably use CreateAndPromote.php for this. AhmadF.Cheema (talk) 07:30, 30 July 2019 (UTC)
Thank you, I look into this! Do you just paste the file in the main folder of the wiki installation? SebastianKazan (talk) 07:34, 30 July 2019 (UTC)
No. This is a command line script that creates one account at a time.
You can create a spreadsheet in excel or your favorite program, with 2 columns for username and password, and a third one with a formula that concatenates them in the command, like this:
"php createAndPromote.php --custom-groups=group1 """&[username column]&""" """&[password column]&""""
Then you can copy and paste that column on your shell.
Note however that this script only adds users, sets their password and adds them to a group, but it doesn't assign them an email address nor does it confirm it. You'll have to manually set the email address in the database (look at the Manual:User table). Ciencia Al Poder (talk) 09:27, 30 July 2019 (UTC)
I understand. Thank you! I do not have access to run command line on the server at the moment, many thanks anyways! 87.128.97.159 (talk) 09:56, 30 July 2019 (UTC)
You may be able to use the API to write a tool to do this if you don't have CLI access. MarkAHershberger(talk) 16:18, 30 July 2019 (UTC)
Thank you Mark but looking at the link I think this would take an unreasonable amount of time for me to figure out, compared to putting in 200 Emails manually...

SebastianKazan (talk) 07:58, 31 July 2019 (UTC)
You may want to check out https://www.mediawiki.org/wiki/Extension:ImportUsers (yeah it says its unmaintained, but afaik it still works fine) Bawolff (talk) 06:36, 2 August 2019 (UTC)
That looks very much like what I was after... I will try and report! Thank you very much! SebastianKazan (talk) 07:00, 2 August 2019 (UTC)
I installed it and it works like a treat! Sweet as! SebastianKazan (talk) 10:44, 2 August 2019 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

InviteSignup

The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.


I succesfully installed the InviteSignup Extension and it works in general BUT:


-Users that have logged-in after receiving the invitation do not show up in the "Signed-Up" window of the extension


- when I set the parameter $wgISGroups in Localsettings.php to

´$wgISGroups = array( 'translator', 'sysop' );

or to any other combination of groups, I get the following error:

[7f8255b23d69b36c8679f494] /index.php?title=Special:InviteSignup ArgumentCountError from line 444 of C:\Inetpub\vhosts\xxx.de\wiki.xxx.de\includes\user\UserGroupMembership.php: Too few arguments to function UserGroupMembership::getGroupMemberName(), 1 passed in C:\Inetpub\vhosts\xxx.de\wiki.xxx.de\extensions\InviteSignup\SpecialInviteSignup.php on line 164 and exactly 2 expected

Backtrace:

#0 C:\Inetpub\vhosts\xxxde\wiki.xxx.de\extensions\InviteSignup\SpecialInviteSignup.php(164): UserGroupMembership::getGroupMemberName(string)

#1 C:\Inetpub\vhosts\xxxde\wiki.xxx.de\extensions\InviteSignup\SpecialInviteSignup.php(90): SpecialInviteSignup->getAddRow()

#2 C:\Inetpub\vhosts\xxx.de\wiki.xxxde\includes\specialpage\SpecialPage.php(569): SpecialInviteSignup->execute(NULL)

#3 C:\Inetpub\vhosts\xxx.de\wiki.xxx.de\includes\specialpage\SpecialPageFactory.php(568): SpecialPage->run(NULL)

#4 C:\Inetpub\vhosts\xxx.de\wiki.xxx.de\includes\MediaWiki.php(288): MediaWiki\Special\SpecialPageFactory->executePath(Title, RequestContext)

#5 C:\Inetpub\vhosts\xxx.de\wiki.xxx.de\includes\MediaWiki.php(860): MediaWiki->performRequest()

#6 C:\Inetpub\vhosts\xxx.de\wiki.xxx.de\includes\MediaWiki.php(517): MediaWiki->main()

#7 C:\Inetpub\vhosts\xxx.de\wiki.xxx.de\index.php(42): MediaWiki->run()

#8 {main}



in line 164 of SpecialInviteSignup.php I find the following:


   $groupChecks = [];

       foreach ( $this->groups as $group ) {

           $groupChecks[] = Xml::checkLabel(

               UserGroupMembership::getGroupMemberName( $group ),

               "group-$group",

               "group-$group"

           );

       }


And in line 444 of includes\user\UserGroupMembership.php I find:


   public static function getGroupMemberName( $group, $username ) {

       $msg = wfMessage( "group-$group-member", $username );

       return $msg->isBlank() ? $group : $msg->text();

   }



SebastianKazan (talk) 07:44, 30 July 2019 (UTC)

So obviously the problem comes because the $username variable isn't set in the calls (there are two of them) from SpecialInviteSignup.php.
The username parameter is used to determine the gender to use in the group message.
I've filed a bug and provided a patch. Please try it and let me know if it works. MarkAHershberger(talk) 16:07, 30 July 2019 (UTC)
Hello Mark,
thank you very much! The error message dissapears and the group names appear. I can also check them. However, the users are not actually assigned to any group.
I can see the group rights in the "user group rights" list (so they do exist) but the invitees are not assigned to them. Also, when signed-in, there is no indication of it in the table under "signed-up".
The button delete: is it supposed to invalidate the invitation link? At the moment it only deletes the line in the table.
I get another error when actually signing-up on the registration page:
Deprecated: Use of UserCreateForm hook (used in InviteSignupHooks:: onUserCreateForm) was deprecated in Wiki 1.27. [Called from Hooks::run in C:\ABC.wiki.de\includes\Hooks.php at line 202] in C:...\include\debug\MWDebug.php on line 309.
Hooks.php line 202:
   public static function run( $event, array $args = [], $deprecatedVersion = null ) {
       foreach ( self::getHandlers( $event ) as $hook ) {
           $retval = self::callHook( $event, $hook, $args, $deprecatedVersion );
           if ( $retval === null ) {
               continue;
           }
MWDebug.php line 309:
   private static function sendMessage( $msg, $caller, $group, $level ) {
       $msg .= ' [Called from ' . $caller['func'] . ' in ' . $caller['file'] . ']';
       if ( $level !== false ) {
           trigger_error( $msg, $level );
       }
       wfDebugLog( $group, $msg, 'private' );
   } SebastianKazan (talk) 07:49, 31 July 2019 (UTC)
A deprecation is not an error, but a warning. For everything else, I think you need to create some tasks for the extension in Phabricator so people know what to work on in this extension. MarkAHershberger(talk) 18:05, 2 August 2019 (UTC)
Do I do that by creating a pull-request at: phacility/phabricator? SebastianKazan (talk) 10:35, 6 August 2019 (UTC)
You do that by creating a task on Wikimedia's phabricator in which you describe the problem you encountered and how it differs from what you expected. MarkAHershberger(talk) 16:16, 6 August 2019 (UTC)
This issue is now fixed in the latest version. Nikerabbit (talk) 07:19, 27 May 2020 (UTC)
The discussion above is closed. Please do not modify it. No further edits should be made to this discussion.

Internal Error during Ldap login

Getting this error:

[739c170df605c75a9e81a05a] /index.php?title=Special:UserLogin&returnto=Main+Page TypeError from line 33 of /var/www/html/SNRTwiki/vendor/symfony/ldap/Adapter/ExtLdap/Query.php: Argument 2 passed to Symfony\Component\Ldap\Adapter\ExtLdap\Query::__construct() must be of the type string, null given, called in /var/www/html/SNRTwiki/vendor/symfony/ldap/Adapter/ExtLdap/Adapter.php on line 64
Backtrace
#0 .../vendor/symfony/ldap/Adapter/ExtLdap/Adapter.php(64): Symfony\Component\Ldap\Adapter\ExtLdap\Query->__construct(Symfony\Component\Ldap\Adapter\ExtLdap\Connection, NULL, string, array)
#1 .../vendor/symfony/ldap/Ldap.php(46): Symfony\Component\Ldap\Adapter\ExtLdap\Adapter->createQuery(NULL, string, array)
#2 .../extensions/LdapAuth/src/Auth/PrimaryAuthenticationProvider.php(530): Symfony\Component\Ldap\Ldap->query(NULL, string, array)
#3 .../extensions/LdapAuth/src/Auth/PrimaryAuthenticationProvider.php(116): Shanept\LdapAuth\Auth\PrimaryAuthenticationProvider->search(Shanept\LdapAuth\Auth\LdapAuthenticationRequest)
#4 .../extensions/LdapAuth/src/Auth/PrimaryAuthenticationProvider.php(88): Shanept\LdapAuth\Auth\PrimaryAuthenticationProvider->beginPrimaryLdapAuthentication(Shanept\LdapAuth\Auth\LdapAuthenticationRequest)
#5 .../includes/auth/AuthManager.php(454): Shanept\LdapAuth\Auth\PrimaryAuthenticationProvider->beginPrimaryAuthentication(array)
#6 .../includes/auth/AuthManager.php(384): MediaWiki\Auth\AuthManager->continueAuthentication(array)
#7 .../includes/specialpage/AuthManagerSpecialPage.php(353): MediaWiki\Auth\AuthManager->beginAuthentication(array, string)
#8 .../includes/specialpage/AuthManagerSpecialPage.php(482): AuthManagerSpecialPage->performAuthenticationStep(string, array)
#9 .../includes/htmlform/HTMLForm.php(660): AuthManagerSpecialPage->handleFormSubmit(array, VFormHTMLForm)
#10 .../includes/specialpage/AuthManagerSpecialPage.php(416): HTMLForm->trySubmit()
#11 .../includes/specialpage/LoginSignupSpecialPage.php(313): AuthManagerSpecialPage->trySubmit()
#12 .../includes/specialpage/SpecialPage.php(569): LoginSignupSpecialPage->execute(NULL)
#13 .../includes/specialpage/SpecialPageFactory.php(558): SpecialPage->run(NULL)
#14 .../includes/MediaWiki.php(288): MediaWiki\Special\SpecialPageFactory->executePath(Title, RequestContext)
#15 .../includes/MediaWiki.php(865): MediaWiki->performRequest()
#16 .../includes/MediaWiki.php(515): MediaWiki->main()
#17 .../index.php(42): MediaWiki->run()
#18 {main}
# LdapAuth config
wfLoadExtension( 'LdapAuth' );
$wgLdapAuthDomainNames = [
    'SNRT'
];
$wgLdapAuthServers = [
    'SNRT' => ['172.16.1.XXX']
];
$wgLdapAuthBindDN = [
    'SNRT' => 'CN=ldap_lookup,CN=Users,DC=snrt,DC=io'
];
$wgLdapAuthBindPass = [
    'SNRT' => 'BindPass'
];
//$wgLdapAuthBaseDN = 'OU=SNRT,DC=snrt,DC=io';
$wgLdapAuthEncryptionType = [
    'SNRT' => 'none'
];
$wgLdapAuthRequireDomain = false;
$wgLdapAuthIsActiveDirectory = true;
//$wgLdapAuthUseLocal = true;
#Enable Scure Login
$wgSecureLogin = true;
Tmhoskins (talk) 14:29, 30 July 2019 (UTC)
Looking at the backtrace, that error is caused because the extension looks for a basedn and, because it can't find one and $wgLdapAuthBaseDN is not set to false, it calls Symfony\Component\Ldap\Adapter\ExtLdap\Query::__construct() with null.
This is a bug in the extension (it should be looking for "falsish" basedns, not strictly the false value). Try un-commenting $wgLdapAuthBaseDN. MarkAHershberger(talk) 15:23, 30 July 2019 (UTC)
I now get this error at the login in screen:
Could not complete search with dn "DC=snrt,DC=io", query "(" and filters "s,givenName,sn,displayName,mail". LDAP error was [-7] Bad search filter
My error.log file shows : PHP Warning:  Illegal string offset 'SNRT' in /var/www/html/SNRTwiki/extensions/LdapAuth/src/Auth/PrimaryAuthenticationProvider.php on line 496, referer: http://snrtwiki.snrt.io/index.php
Which I have been taking as my LocalSettings.php is passing a bad value. Tmhoskins (talk) 15:54, 30 July 2019 (UTC)
I was wrong. You need to do more than just uncomment $wgLdapAuthBaseDN. Instead, set it to:
$wgLdapAuthBaseDN = [
    'SNRT' => 'OU=SNRT,DC=snrt,DC=io'
];
MarkAHershberger(talk) 16:15, 30 July 2019 (UTC)
I already did this and got the same error as above. I then removed the OU part thinking it was giving me issues and got the error once again. Also wehre is it pulling these search filters from query "(" and filters "s,givenName,sn,displayName,mail"? Tmhoskins (talk) 16:37, 30 July 2019 (UTC)
Your PHP error log still shows PHP Warning:  Illegal string offset 'SNRT' after you used this in your LocalSettings.php?:
$wgLdapAuthBaseDN = [
    'SNRT' => 'OU=SNRT,DC=snrt,DC=io'
];
MarkAHershberger(talk) 21:14, 30 July 2019 (UTC)
Ok, I'm just reading code here and trying to help you out. I wasn't aware of this extension before you asked about it.
In any case:
wehre is it pulling these search filters from query "(" and filters "s,givenName,sn,displayName,mail"?
Your answer is here.
It looks like a bug in the code is somehow getting only the first character of the default value of $wgLdapAuthUsernameField (which is "sAMAccountName") and returning that.
You should probably post an issue on the author's github repo. MarkAHershberger(talk) 21:47, 30 July 2019 (UTC)
Yes my LocalSettings.php are:
# LdapAuth config
wfLoadExtension( 'LdapAuth' );
$wgLdapAuthDomainNames = [
'SNRT'
];
$wgLdapAuthServers = [
'SNRT' => ['172.16.1.248']
];
$wgLdapAuthBindDN = [
'SNRT' => 'CN=ldap_lookup,CN=Users,DC=snrt,DC=io'
];
$wgLdapAuthBindPass = [
'SNRT' => 'ZPLV72p7jGTYi8eLgaEmnzFnsAfj15YB'
];
$wgLdapAuthBaseDN = [
'SNRT' => 'OU=SNRT,DC=snrt,DC=io'
];
//$wgLdapAuthSearchFilter = [
//'SNRT' => '(&(objectClass=SNRT)(displayName=%1$s))'
//];
$wgLdapAuthEncryptionType = [
'SNRT' => 'tls'
];
$wgLdapAuthRequireDomain = false;
$wgLdapAuthIsActiveDirectory = true;
//$wgLdapAuthUseLocal = true;
#Enable Scure Login
$wgSecureLogin = true;
When I try to login using the LdapAuth extension I the error:
Could not complete search with dn "OU=SNRT,DC=snrt,DC=io", query "(" and filters "s,givenName,sn,displayName,mail". LDAP error was [-7] Bad search filter
Obviously the webserver is tryin gto communicate with the AD server but the code has errors. This has been the issue all along, the code that the extension lists as configuration was misleading. You can't just set a string value in most of them settings, they have to be arrays. I am posting this to the author's GitHub too.

Tmhoskins (talk) 12:36, 31 July 2019 (UTC)

Extension:CustomNavBlocks

appears to be unmaintained. 74.196.230.108 (talk) 22:28, 30 July 2019 (UTC)

Sounds likely; no updates in 5 years. Someone did submit a pull request earlier this year though, so perhaps there is interest in reviving it. Sam Wilson 01:47, 1 August 2019 (UTC)

Where to prevent pages from certain namespaces appear in "Recent changes" list?

Hello and thanks in advanced.

In MediaWiki 1.32.0 I have some pages by the namespace of draft:. That is, such a web page can be named:

draft:MyDraft

Where could I set that all pages from a certain space (in this case, draft:) will never appear in MediaWiki's "Recent changes" list?

<small>I am not talking about filtering them out from Recent changes list results but to make them never appear there, whatever filtering will be used.</small> 103.199.27.156 (talk) 04:17, 31 July 2019 (UTC)

See Manual:Recent changes. AhmadF.Cheema (talk) 07:29, 31 July 2019 (UTC)

We have to change our wiki server's ip and web address. We have so many pages with links to documents inside our wiki server that are defined like absolute url like below:

[ http://#SERVERNAME#/index.php/Dosya:SSB-%C5%9EB-%C3%9CST-1.2_Politika_%C5%9Eablonu.docx #Document Name# ]


when we change our server name, will those links be broken? What do we have to do to prevent this?


Kind regards 92.45.61.4 (talk) 15:23, 31 July 2019 (UTC)

You could try Extension:Replace Text. Jonathan3 (talk) 00:56, 1 August 2019 (UTC)
In the future, you should instead use relative links like [[:Dosya:SSB-ŞB-ÜST-1.2_Politika_Şablonu.docx|#Document Name#]]. That way they will always be for the right server. (Adding a colon at the beginning makes sure that it links to a file instead of displaying the file) Bawolff (talk) 06:33, 2 August 2019 (UTC)
If you're in a hurry and don't want to fix all the links, in case the only change is the domain name or IP and not the path, you can use this extension that I developed: https://github.com/ciencia/mediawiki-extensions-MigrateMyLinks Ciencia Al Poder (talk) 10:05, 2 August 2019 (UTC)

$wgServer does not appear in LocalSettings.php

Hello guys I actually tried to edit $wgServer in LocalSettings.php, but it seems not to appear (Ctrl + F "$wgServer). Am I doing something wrong? 178.59.28.91 (talk) 23:39, 31 July 2019 (UTC)

You can add it in if it's not there. Just add e.g. $wgServer = "https://example.org";
What documentation are you following that assumes it exists? (We could probably update it to make it clearer.) Sam Wilson 00:35, 1 August 2019 (UTC)
It should always exist for newer installs (Since roughly 1.16 i think the installer added it by default, not exactly sure when).
It is a minor security issue if it is auto-detected instead of specified explicitly. Newer versions of MediaWiki will require that it is explicitly specified Bawolff (talk) 06:31, 2 August 2019 (UTC)
Category:Indexed pages Category:Noindexed pages Category:Support desk archives Category:Support desk archives using deprecated source tags Category:Support desk archives with syntax highlighting errors