Project:Support desk/Flow/2022/08
| This page used the Structured Discussions extension to give structured discussions. It has since been converted to wikitext, so the content and history here are only an approximation of what was actually displayed at the time these comments were made. |
| This page is an archive. |
| Please ask questions on the current support desk. |
Enabling plugins breaks my wiki (error 500)
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 trying to create my first wiki, but I seem to not be able to activate (wfLoadExtension) any extensions that weren't installed by default, or else the site completely breaks (immediately gives error 500, internal server error). If I disable those extensions, the site automatically starts working again. Possibly of note is that the maintenance/update.php script doesn't seem to do anything while extensions are enabled either; I didn't test any other scripts, but they probably break too. As long as I don't activate any extensions, everything appears to work fine.
I'm using Apache on a shared server (Namecheap). I already have several websites successfully hosted on this server. The Apache logs don't appear in /var/log/apache/ (it's possible they're hidden, which makes sense considering it's a shared server). Editing LocalSettings.php to tell it to show PHP tracebacks doesn't change anything; I still get the same error.
This is my installed software displayed on Special:Version (I am intentionally not using the latest versions of MediaWiki for compatibility with Semantic Text Annotator):
| MediaWiki | 1.31.16 |
| PHP | 7.4.30 (litespeed) |
| MariaDB | 10.3.35-MariaDB-cll-lve |
| ICU | 63.1 |
My wiki is located at https://irony.gabl.ink/. You can also look at https://irony.gabl.ink/index.php/Special:Version for more info. (The main page and Special:Version are the only two publicly-accessible pages at the moment, but you can let me know if you need to look at some more to help.)
Thank you!
EDIT: I'm trying to install Semantic MediaWiki, Page Forms, and Semantic Text Annotator]. The latter actually works fine, but the other two break the site upon activation. I'm trying to install the first two using Composer (1.x) while the latter is cloned from a GitHub repository, so that might be the source of the problem somehow. I'll update this if I figure that out.
EDIT 2: I found the MediaWiki logs. The packages I was trying to use were too new. Of course they were. I can probably figure this out on my own now, but I'll wait on marking this off as solved until I'm sure. Gabldotink (talk) 02:03, 1 August 2022 (UTC)
- 1.31.16 is an old, insecure, unsupported version full of security vulnerabilities nowadays. Please run supported and secure software for your own safety. Malyacko (talk) 14:34, 1 August 2022 (UTC)
PROBLEM AND ERROR WHEN I WANT TO Create a new Item
Hello I hope everyone is doing well I get the error below when I click on the option to create a new item
This action has been automatically identified as harmful, and therefore disallowed. If you believe your action was constructive, please inform an administrator of what you were trying to do. A brief description of the abuse rule which your action matched is: Spam I haven't broken any law and I think the system has made a mistake in this case, thank you for opening my access. thank you Pouyamoradzad (talk) 13:24, 1 August 2022 (UTC)
- @Pouyamoradzad Hi, what is a "new item", and where? Please read "Post a new question" in the sidebar. Thanks! Malyacko (talk) 14:33, 1 August 2022 (UTC)
- HI...THE CREAT THE NEW ITEM PART IS ON WIKIDATA WEBSITE AND AFTER SEARCHING ON WEB FOR SOLUTION THAT TAKE ME HERE TO HELP ME IN THIS CASE Pouyamoradzad (talk) 12:08, 2 August 2022 (UTC)
- @Pouyamoradzad See the error message that you posted. What is unclear with the error message? Malyacko (talk) 05:16, 3 August 2022 (UTC)
- As the error said, complain to an admin. If this was at wikidata, complain to a wikidata admin. We arent wikidata admins at this website. Bawolff (talk) 06:26, 3 August 2022 (UTC)
- i know ...but the wikidata talk page redirected me to this site for support and give permissions from admins Pouyamoradzad (talk) 10:26, 5 August 2022 (UTC)
- then you probably misunderstood the talk page. Bawolff (talk) 23:26, 7 August 2022 (UTC)
Missing files after migrating from 1.32 to 1.38
Hi all. I'm trying to migrate from 1.32 to 1.38. This wiki originally migrated from Wikia/Fandom in 2018. I'm currently having issues with some older files not migrating properly.
These files are available on the server, but there pages in Files: no longer exist.
Examples: Live site =bakugan.wiki, migration site =beta.bakugan.wiki
https://bakugan.wiki/wiki/File:Sun_Fire_Start_(NA).png
https://beta.bakugan.wiki/wiki/File:Sun_Fire_Start_(NA).png
https://bakugan.wiki/images/8/81/Sun_Fire_Start_%28NA%29.png
https://beta.bakugan.wiki/images/8/81/Sun_Fire_Start_%28NA%29.png
Any help is greatly appreciated. 2601:145:603:24E0:0:0:0:90D4 (talk) 14:43, 1 August 2022 (UTC)
- I realize I didn't link the new site properly.
- The new site is on the 'beta' subdomain for those who want to look into it. Seewhati (talk) 14:49, 1 August 2022 (UTC)
- So possibilities:
- rows from the image table werent migrated properly and are missing.
- its a problem with the actor migration. I.e. img_actor field on the db row for those images are wrong, and maybe cleanupUsersWithNoId.php needs to be run (on the older version of the db) Bawolff (talk) 15:16, 1 August 2022 (UTC)
- Tried running the cleanupUsers and migrateActors and the live site and now I have broken file embeds as seen here. https://bakugan.wiki/wiki/Sun_Fire_Start
- EDIT: Cloudflare Caching was hiding the fact that the file was indeed missing. Seewhati (talk) 16:08, 1 August 2022 (UTC)
- @Bawolff See also https://bakugan.wiki/wiki/1-48c_(Gundalian_Invaders)
- migrateActors+cleanupUsersWithNoId broke images in the same way as on the new install. Seewhati (talk) 16:19, 1 August 2022 (UTC)
- Update, running cleanupUsersWithNoId.php and migrateActors.php on the 1.32 live wiki breaks images like in the migrated wiki.
- EDIT: Images actually aren't broken in the same way. It seems that resized images are now broken.
- EDIT 2: Cloudflare caching was hiding the fact that images are indeed broken in the same way. Seewhati (talk) 16:03, 1 August 2022 (UTC)
- Can you check in your db, does there exist a row in image table where img_name matches the file name in question. What is the img_actor and img_comment_id fields, and the id numbers correspond to rows in thr actor and comment table respectively? Bawolff (talk) 16:49, 1 August 2022 (UTC)
- I'm a total database noob. What would the best way to get this information? I can acees the DB through either phpmyadmin or commandline, Seewhati (talk) 17:04, 1 August 2022 (UTC)
- You can use the following sql (replace PUTDBNAMEHERE with your database name):
use PUTDBNAMEHERE;SELECT * from image where img_name = "Sun_Fire_Start_(NA).png";- And then copy and past what comes out. If the image is truly not in the DB, it might just output 0 rows, but if there is some sort of referential integrity issue, we should get some output. Bawolff (talk) 01:20, 2 August 2022 (UTC)
- No idea if this is going to format properly or not but
- Seewhati (talk) 03:39, 2 August 2022 (UTC)
+--------------------------------------------------+----------+-----------+----- -------+------------------------------------------------------------------------ -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- ----------------------------------------------------------------+----------+---- ----------------------------+--------------------------------+------------------ --------------+----------------------------------+--------------------+--------- -+------------------------------+-----------+--------------------------------+-- ----------------------------------------------------------------+ | img_name | img_size | img_width | img_ height | img_metadata | img_bits | img _media_type | img_major_mime | img_minor_mime | img_description | img_description_id | img_user | img_user_text | img_actor | img_timestamp | i mg_sha1 | +--------------------------------------------------+----------+-----------+----- -------+------------------------------------------------------------------------ -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- ----------------------------------------------------------------+----------+---- ----------------------------+--------------------------------+------------------ --------------+----------------------------------+--------------------+--------- -+------------------------------+-----------+--------------------------------+-- ----------------------------------------------------------------+ | 0x53756E5F466972655F53746172745F284E41292E706E67 | 524488 | 421 | 565 | 0x613A363A7B733A31303A226672616D65436F756E74223B693A303B733A393A226C6F6 F70436F756E74223B693A313B733A383A226475726174696F6E223B693A303B733A383A226269744 465707468223B693A383B733A393A22636F6C6F7254797065223B733A31303A2274727565636F6C6 F7572223B733A383A226D65746164617461223B613A353A7B733A31313A22585265736F6C7574696 F6E223B733A383A22333737392F313030223B733A31313A22595265736F6C7574696F6E223B733A3 83A22333737392F313030223B733A31343A225265736F6C7574696F6E556E6974223B693A333B733 A383A22536F667477617265223B613A323A7B733A393A22782D64656661756C74223B733A31363A2 27061696E742E6E657420342E302E3231223B733A353A225F74797065223B733A343A226C616E672 23B7D733A31353A225F4D575F504E475F56455253494F4E223B693A313B7D7D | 8 | 0x4 249544D4150 | 0x696D616765 | 0x706E67 | 0x | 0 | 1357348 | 0x4162636532 | 0 | 0x3230313830363031303435343334 | 0 x643536316D7167376472746A6E346B32326639653639726E3367686B673138 | +--------------------------------------------------+----------+-----------+----- -------+------------------------------------------------------------------------ -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- -------------------------------------------------------------------------------- ----------------------------------------------------------------+----------+---- ----------------------------+--------------------------------+------------------ --------------+----------------------------------+--------------------+--------- -+------------------------------+-----------+--------------------------------+-- ----------------------------------------------------------------+
- So it does look like the img_actor field is 0 here, but img_user is not 0 (It is 1357348), so its some sort of problem with running migrateActors.php and not a cleanupUsersWithNoId issue.
- This is the updated DB right, not the original?
- I guess you could try running migrateActors.php again see if that helps, and see if it reports any errors. Bawolff (talk) 22:39, 2 August 2022 (UTC)
- edit: replied above Seewhati (talk) 17:03, 1 August 2022 (UTC)
How to undo vandalism?
How can I, as a normal contributor, undo an edit like [https://www.mediawiki.org/w/index.php?title=User_talk:Privateisland101&header_revId=x0htdo9aoel7gzat&action=view-header this] or [https://www.mediawiki.org/w/index.php?title=Topic:X0ht8zukx5d3rg80&topic_postId=x0ht8zukx9b5zk68&topic_revId=x0ht8zukx9b5zk68&action=single-view this]? Both are clearly unwanted advertisements. Until recently, it was easy to undo an edit, but I got lost in theses talk talk pages... Thanks for explication (and for removing these edits). ~ RonnieV (talk) 23:22, 2 August 2022 (UTC)
- Flow is confusing for moderation tools. If its a new topic there is a "..." menu by the header that has a button labeled "delete topic". However im not sure if i only get that because im an admin, so maybe normal users dont. Im not sure. Bawolff (talk) 06:24, 3 August 2022 (UTC)
- Thanks for your answer, Bawolff. Not being an admin, I only see 'Edit title', 'History', 'Permalink' and 'Summarize'. Now I can (for this thread) also choose for 'Mark as resolved' and 'Hide topic'.
- I am afraid we will not (at least temporary) restore the old, maybe visually less attractive (taste...), but completely working way of editing on this project. I d do hope we will soon have good and complete options for 'normal' editors to undo unwanted edits, to prevent garbage like the mentioned edit to stay here any longer than strictly necessary... Thanks, those who did the job, for removing these edits. RonnieV (talk) 17:34, 3 August 2022 (UTC)
- I wouldn't hold your breath for changes to flow "editing". Its been like this forever and now is basically an abandoned project. Bawolff (talk) 04:07, 4 August 2022 (UTC)
Reading data from wiki and send another system
Hello I don't know how wiki work and store data but my company uses wiki and they want to send data wiki to another system, they want to store some data also SAP database.
How can we read data from wiki to another system? Please help, it is so important.
I need examples. I can't able to reach any professional helping us. Sifapala (talk) 12:26, 3 August 2022 (UTC)
- Help:Export for exporting; API:Main page for reading. Malyacko (talk) 12:41, 3 August 2022 (UTC)
Parser output text not interpreted
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 trying to write a parser for my mediawiki project. I have created an extension no problem and the hook works and the code is being executed.
My parser, based on the examples, is trying to create an autogenerated internal link rather than this being done manually by a user.
The function is:
public static function renderTagWork( $input, array $args, Parser $parser, PPFrame $frame ) {
$returnString = "[[";
$returnString .= $args["workname"];
$returnString .= " (";
$returnString .=$args["composer"];
$returnString .= " )|";
$returnString .= $args["workname"];
$returnString .= "]]";
return $returnString;
}
However, when this is rendered on the page, the user just sees the text [[ and ]] rather than actually seeing an internal link. i.e the output is not being interpreted. How do I fix this?
Thanks Bigtallduck (talk) 13:17, 3 August 2022 (UTC)
- See Manual:Parser functions#Controlling the parsing of output. Clump (talk) 16:48, 3 August 2022 (UTC)
- Thanks for the reply, that looks like it should have worked, but unfortunately this didn't seem to make any difference. I made the code really simple:
- $returnString = "[[ testing ]]";
- return [ $returnString, 'noparse' => false ];
- It still just displays the text with the brackets [[ ]]
- Any ideas? Bigtallduck (talk) 09:24, 4 August 2022 (UTC)
- Are you actually creating a parser extension or a tag extension? I assumed the former, but based on your function signature I guess it's the latter? In that case see Manual:Tag extensions#How do I render wikitext in my extension?. Clump (talk) 13:24, 4 August 2022 (UTC)
- That worked perfectly thanks! Bigtallduck (talk) 09:32, 5 August 2022 (UTC)
Mediawiki LTS version 1.35.6with outdated jquery vulnerability
We have Mediawiki v1.35.6 (LTS) version installed on our environments. We have being flagged with out of date jquery libraries and being asked to upgrade the jquery to the latest packages.
- jquery 3.4.1 needs to be upgraded to latest version v3.6
- jQuery UI Autocomplete/Dialog/Tooltip is 1.9.2 while the latest version is 1.1
Considering the LTS stable version v1.35, we are not inclined to upgrade to latest MW version (1.37)
Please let us know what's the approach for jquery package update. Armfns001 (talk) 13:52, 3 August 2022 (UTC)
- @Armfns001 If you still run outdated 1.35.1 then you should upgrade to MediaWiki 1.35.7 to fix security issues. See also Release notes/1.35. Malyacko (talk) 17:44, 3 August 2022 (UTC)
- We did upgrade to v1.35.6 last week.
- However the jquery vulnerability still seems to be persistent.
- Is there an hotfix or patch to update those libraries?
- Thanks 96.241.75.247 (talk) 18:13, 3 August 2022 (UTC)
- The security issues in jquery 3.4.1 are very minor and seem extremely unlikely to be exploitable in practise (they are about passing unsafe input to a function where it was already unsafe to pass untrusted input) to the point where i wouldn't describe it as a security issue but "hardening".
- jquery-ui, while i am still pretty sure is not exploitable in context, is a bit harder to defend. As far as i know, it is no longer used or loaded by mediawiki core and only loaded if an extension asks for it. Bawolff (talk) 04:04, 4 August 2022 (UTC)
Issues after upgrading to 1.38.2
We're currently running our production wiki on 1.35. Since everything is working fine there, I created a copy of our DB, and installed 1.38.2
The basics for viewing the wiki seem to be OK, however there are certain UI elements that fail to respond correctly (namely things in the User Preferences panel). In the browser error console I have the following error: Uncaught ReferenceError: $VARS is not defined
at load.php?lang=en&modules=startup&only=scripts&raw=1&skin=monobook:4:993 at load.php?lang=en&modules=startup&only=scripts&raw=1&skin=monobook:24:297
Note that it doesn't matter what skin I use, I still see the same error. Blinkingline (talk) 19:03, 3 August 2022 (UTC)
Russian language font size
In the Wiki family that I help manage, the Russian language site has a bigger font, although they have the same parameters as the English one. If I use Russian text in the English site, they have the same size, but the Russian site has a bigger font.
The same phenomenon happens in Russian Wikipedia, by the way. How do I normalize text size to be the same among all wikis? Marx.FelipeForte (talk) 20:00, 3 August 2022 (UTC)
MW 1.35.6 - Cookie Not Marked as Secure remediation
Our system is flagged with a vulnerability that "Cookie Not Marked as Secure" and needs to remediate so that all cookies used within the application as secure.
Our system is setup behind an apache reverse proxy (on Web server) and the MW application hosted on its own separate apache server. The call from outside world to reach the application is on "https" protocol and the reverse proxy redirects the call to the MW application is utilizing "http".
Enabling the Cooke secure (Manual:$wgCookieSecure) variable in LocalSettings works on application access however it breaks some of the functionalities within the application that require http communication.
Please recommend an approach that can be used to keep the cookie secured.
Environment:
MW 1.35.6, PHP 7.4.30 Armfns001 (talk) 20:06, 3 August 2022 (UTC)
- > however it breaks some of the functionalities within the application that require http communication.
- Can you be more specific. The setup you are describing does not seem to involve http communication. Bawolff (talk) 03:41, 4 August 2022 (UTC)
- Our MW application involves a renderbook functionality that needs a http communication between the Mediawiki apache and the Renderserver to provide ebook functionality. Making the wsCokkieSecure hinders the https communication betweem the MW and Renderserver. Let me know if you need additional details. Armfns001 (talk) 14:45, 25 August 2022 (UTC)
No such service: DBLoadBalancerFactory
I updated from 1.13 via 1.26 to 1.35 - that went relatively smooth.
Now I am trying to update to 1.38.2 and get an exception that I cannot read. What is missing?
Uncaught Wikimedia\\Services\\NoSuchServiceException: No such service: DBLoadBalancerFactory in /home/web/htdocs-wiki1.38.2/vendor/wikimedia/services/src/ServiceContainer.php:468
Stack trace:
#0 /home/web/htdocs-wiki1.38.2/vendor/wikimedia/services/src/ServiceContainer.php(416): Wikimedia\\Services\\ServiceContainer->createService('DBLoadBalancerF...')
#1 /home/web/htdocs-wiki1.38.2/includes/MediaWikiServices.php(294): Wikimedia\\Services\\ServiceContainer->getService('DBLoadBalancerF...')
#2 /home/web/htdocs-wiki1.38.2/includes/MediaWikiServices.php(928): MediaWiki\\MediaWikiServices->getService('DBLoadBalancerF...')
#3 /home/web/htdocs-wiki1.38.2/includes/exception/MWExceptionHandler.php(136): MediaWiki\\MediaWikiServices->getDBLoadBalancerFactory()
#4 /home/web/htdocs-wiki1.38.2/includes/exception/MWExceptionHandler.php(201): MWExceptionHandler::rollbackPrimaryChangesAndLog(Object(Wikimedia\\Services\\NoSuchServiceException), 'mwe_handler')
#5 /home/web/htdocs-wiki1.38.2/includes/exception/MWExceptionH in /home/web/htdocs-wiki1.38.2/vendor/wikimedia/services/src/ServiceContainer.php on line 468 217.111.27.204 (talk) 21:52, 3 August 2022 (UTC)
- Are you sure you have allthe files for mw 1.38.2 and none of then are missing or a mix of different versions? Bawolff (talk) 03:39, 4 August 2022 (UTC)
- I tried again to make sure: I have a clean unpacked mediawiki and an existing database. All I add before running "php update.php" is LocalSettings.php and the Auth_remoteuser plugin. Now (on second attempt) I see a message about HookContainer not beeing found in the same style as as avove "NoSuchServiceException"
- All updates until 1.37.4 work fine (I see the logon-page) 192.31.14.13 (talk) 13:13, 5 August 2022 (UTC)
Error: Missing one or more required components of PHP.
I'm running a mediawiki instance on windows, everything works except running php commands.
Error: Missing one or more required components of PHP. You are missing a required extension to PHP that MediaWiki needs. Please install: * mbstring <https://www.php.net/mbstring> * fileinfo <https://www.php.net/fileinfo> * intl <https://www.php.net/intl>
Other than that, the wiki works perfectly but I need to have this fixed. I looked it up already but all the answers were for linux, and I'm on windows. I have the extensions on in php.ini-production and I have the dlls for them. 2600:1700:A9B0:42B0:9012:443:947A:FBEB (talk) 22:36, 3 August 2022 (UTC)
- Command line php usually uses a different .ini file than the webserver php. So you probably have to find the right ini file and copy over the lines liading the extension.
- On the commandline, there is the --ini argument that tells you where the .ini files are located. Bawolff (talk) 03:38, 4 August 2022 (UTC)
- Alright I think i fixed it, i copied the production file to php.ini and ran it and i got no error (finally). Thanks!!!! 2600:1700:A9B0:42B0:9012:443:947A:FBEB (talk) 16:46, 4 August 2022 (UTC)
invalid csrf token
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 am using mediawiki 1.38.2 since many weeks (and mediawiki since many years).
today i cant logout and login. they say: "invalid csrf token". the problem is the same with different users and different pc.
the only thing i can suppose changed in last days is that yesterday the server grow up the RAM memory.
now i cant edit my site. can someone please help me? thank You Brunodapei (talk) 16:54, 4 August 2022 (UTC)
Stop Violating Copyrights
Hello,
I'm the photographer of this image, I'm asking to delete it ASAP, such picture should only be available on Microstock websites that I'm contributing with.
https://commons.wikimedia.org/wiki/File:Al-Riyad.jpg 129.208.102.87 (talk) 18:35, 4 August 2022 (UTC)
- Hi. This is the wrong place to make this request (This forum is for technical issues not copyright issues). However it does look like you filed the request in the correct place as well ( https://commons.wikimedia.org/wiki/Commons:Deletion_requests/File:Al-Riyad.jpg . Note, sometimes it can take a week for such requests to be processed). If you need further assistance in this matter, ask at commons:Commons:Help desk. Thanks. Bawolff (talk) 22:21, 4 August 2022 (UTC)
$wgAllowExternalImages set to true isn't working
Hi, I'm setting up a new wiki that is going to allow external image so I set $wgAllowExternalImages to be true, but the wiki still isn't letting me do it. Thoughts? Christharp (talk) 18:42, 4 August 2022 (UTC)
- Never mind I got it working. Christharp (talk) 02:51, 5 August 2022 (UTC)
- It would be good to know what was wrong and how you fixed it. Jonathan3 (talk) 08:19, 5 August 2022 (UTC)
Does Mediawiki now disallow all background images?
I tried adding a background image via the css extension & it failed. I thought maybe it was just an issue with the extension so than I tried with the common.css & it also failed. Christharp (talk) 02:50, 5 August 2022 (UTC)
- Nothing has changed in regards to background-images (i.e. common.css and E:CSS allows anything, inline style attributes does not allow urls, and extension:TemplateStyles only allows it if it is from a list of allowed sites configured in LocalSettings.php)
- Are you sure you used the correct syntax, didn't make a typo, etc. Bawolff (talk) 06:52, 5 August 2022 (UTC)
Mediawiki 1.37 mit Kerberos und LDAP Anmelde - Button aktivieren
Mediawiki 1.37.0, PHP 7.4.26: Wir betreiben mehrere Wikis für unsere Kunden. Die laufen alle mit Kerberos und LDAP Authentifizierung. Zudem ist das Extension ‘Auth_remoteuser’ installiert. Ich habe jedoch keine Möglichkeit mich in den Wikis mit dem Admin Account anzumelden, obwohl dieser bei der Installation in den Wikis erstellt wurde. Der Wiki Admin Account ist bei uns nicht in der AD erfasst. Der Button für die Anmeldung in die Wikis ist nicht vorhanden. Wie kann ich diesen trotz Kerberos und LDAP aktivieren. Kann mir da jemand einen Tipp geben? Dansnider (talk) 07:51, 5 August 2022 (UTC)
- @Dansnider If you still run MediaWiki 1.37.0 then you run an outdated insecure software version. Please update to a supported version for your own safety. Malyacko (talk) 09:43, 8 August 2022 (UTC)
Various Error with LDAP modules
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.
Try and errors
When I try to authenticate as
an LDAP User , I got this error : [ec6935bb5d6a9b7d0d944cdd] 2022-08-05 13:21:20: Erreur fatale de type « MWException »
a Local User : I got this error : Could not authenticate
All the /LDAPProvider/maintenance/ scripts works fine ie : CheckConnection.php CheckLogin.php ConvertLdapAuthenticationConfig.php ShowUserGroups.php ShowUserInfo.php
Versions
MediaWiki 1.35.4
PHP 7.4.30 (apache2handler)
MariaDB 10.5.15-MariaDB-0+deb11u1
ICU 67.1
LDAPAuthentication 2 1.0.3 (6bc5848) 22 juillet 2022 à 10:15
LDAPAuthorization 1.1.0 (a0d1a5b) 4 juillet 2022 à 07:18
LDAPProvider 1.0.5 (80f8cc8) 22 juillet 2022 à 11:29
PluggableAuth 5.7 (a932c78) 23 mai 2022 à 21:17
Configs
- ldapprovider-aaa.json
{
"example.com": {
"connection": {
"server": "ad.example.com",
"port": "636",
"enctype": "ssl",
"user": "cn=ldap-connect,cn=Users,dc=example,dc=com",
"pass": "********",
"options": {
"LDAP_OPT_DEREF": 1
},
"basedn": "cn=Users,dc=example,dc=com",
"groupbasedn": "cn=Users,dc=example,dc=com",
"userbasedn": "cn=Users,dc=example,dc=com",
"searchattribute": "sAMAccountName",
"searchstring": "cn=USER-NAME,cn=Users,dc=example,dc=com",
"usernameattribute": "sAMAccountName",
"realnameattribute": "displayName",
"emailattribute": "mail",
"grouprequest": "MediaWiki\\Extension\\LDAPProvider\\UserGroupsRequest\\UserMemberOf::factory"
},
"authorization": {
"rules": {
"groups": {
"required": [ "CN=wikiaaa,CN=Users,dc=example,dc=com" ]
}
}
}
}
}
- LocalSettings.php
<?php
if ( !defined( 'MEDIAWIKI' ) ) {
exit;
}
$wgSitename = "Wiki aaa";
$wgScriptPath = "";
$wgScriptExtension = ".php";
$wgServer = "https://wikiaaa.example.com";
$wgStylePath = "$wgScriptPath/skins";
$wgLogo = "$wgStylePath/common/images/logo_aaa.png";
$wgGroupPermissions['*']['createaccount'] = false;
$wgGroupPermissions['user']['createaccount'] = true;
$wgGroupPermissions['wikiaaa']['createaccount'] = true;
$wgGroupPermissions['*']['read'] = false;
$wgGroupPermissions['*']['edit'] = false;
$wgGroupPermissions['sysop']['edit'] = true;
$wgGroupPermissions['user']['edit'] = true;
$wgGroupPermissions['aaa']['edit'] = true;
$wgEnableEmail = false;
$wgEnableUserEmail = true; # UPO
$wgEmergencyContact = "apache@wikiaaa.example.com";
$wgPasswordSender = "apache@wikiaaa.example.com";
$wgEnotifUserTalk = false; # UPO
$wgEnotifWatchlist = false; # UPO
$wgEmailAuthentication = true;
$wgDBtype = "mysql";
$wgDBserver = "localhost";
$wgDBname = "wikiaaa";
$wgDBuser = "userwikiaaa";
$wgDBpassword = "**********";
$wgDBprefix = "";
$wgDBTableOptions = "ENGINE=InnoDB, DEFAULT CHARSET=utf8";
$wgDBmysql5 = false;
$wgMainCacheType = CACHE_NONE;
$wgMemCachedServers = array();
$wgEnableUploads = true;
$wgUseImageMagick = true;
$wgImageMagickConvertCommand = "/usr/bin/convert";
$wgFileExtensions = array('png', 'gif', 'jpg', 'jpeg', 'pdf', 'dmg', 'ppd', 'zip', 'doc', 'docx');
$wgUseInstantCommons = false;
$wgShellLocale = "fr_FR.utf8";
$wgLanguageCode = "fr";
$wgSecretKey = "6gyo8sj9a2d20vsdh7t51r080s0kqk5tdlx08zxolbxrtui8e7frd0hkxv7xoki825n756";
$wgUpgradeKey = "jbkvvpd7nr";
$wgDefaultSkin = "vector";
wfLoadSkin( 'Vector' );
$wgRightsPage = ""; # Set to the title of a wiki page that describes your license/copyright
$wgRightsUrl = "";
$wgRightsText = "";
$wgRightsIcon = "";
$wgDiff3 = "/usr/bin/diff3";
if (is_file("/etc/mediawiki-extensions/extensions.php")) {
include("/etc/mediawiki-extensions/extensions.php");
}
$wgResourceLoaderMaxQueryLength = -1;
wfLoadExtension( 'SyntaxHighlight_GeSHi' );
wfLoadExtension( 'AccessControl' );
wfLoadExtension( 'Math' );
wfLoadExtension( 'WikiEditor' );
wfLoadExtension( 'LabeledSectionTransclusion' );
wfLoadExtension( 'LDAPAuthorization' );
wfLoadExtension( 'LDAPAuthentication2' );
wfLoadExtension( 'PluggableAuth' );
wfLoadExtension( 'LDAPProvider' );
$LDAPAuthentication2AllowLocalLogin = true;
$LDAPAuthentication2UsernameNormalizer = true;
$LDAPProviderDomainConfigs = "/etc/mediawiki/ldapprovider-aaa.json";
$wgDebugLogGroups['PluggableAuth'] = "/var/log/mediawiki/debug-{$wgDBname}.log";
$wgDebugLogGroups['MediaWiki\\Extension\\LDAPProvider\\Client'] = "/var/log/mediawiki/debug-{$wgDBname}.log";
$wgDebugLogGroups['LDAPAuthentication2'] = "/var/log/mediawiki/debug-{$wgDBname}.log";
$wgDebugLogGroups['LDAPAuthorization'] = "/var/log/mediawiki/debug-{$wgDBname}.log";
$wgDebugLogGroups['LDAPProvider'] = "/var/log/mediawiki/debug-{$wgDBname}.log";
wfLoadExtension( 'Cite' );
wfLoadExtension( 'Mpdf' );
$wgMpdfTab = true;
$wgMpdfToolboxLink = true;
Logs
#Local user 2022-08-05 13:43:13 wikiaaa.example.com wikiaaa: In execute() 2022-08-05 13:43:13 wikiaaa.example.com wikiaaa: Getting PluggableAuth singleton 2022-08-05 13:43:13 wikiaaa.example.com wikiaaa: Class name: MediaWiki\Extension\LDAPAuthentication2\PluggableAuth 2022-08-05 13:43:13 wikiaaa.example.com wikiaaa: Authentication failure. 2022-08-05 13:43:13 wikiaaa.example.com wikiaaa: ERROR: Could not authenticate # LDAP user 2022-08-05 13:45:34 wikiaaa.example.com wikiaaa: In execute() 2022-08-05 13:45:34 wikiaaa.example.com wikiaaa: Getting PluggableAuth singleton 2022-08-05 13:45:34 wikiaaa.example.com wikiaaa: Class name: MediaWiki\Extension\LDAPAuthentication2\PluggableAuth 2022-08-05 13:45:35 wikiaaa.example.com wikiaaa: Setting LDAP_OPT_PROTOCOL_VERSION to 3 2022-08-05 13:45:35 wikiaaa.example.com wikiaaa: Setting LDAP_OPT_REFERRALS to 0 2022-08-05 13:45:35 wikiaaa.example.com wikiaaa: Setting LDAP_OPT_DEREF to 1 2022-08-05 13:45:35 wikiaaa.example.com wikiaaa: MediaWiki\Extension\LDAPProvider\Client::getSearchString: User DN is: 'cn=user1,cn=Users,dc=example,dc=com' 2022-08-05 13:45:35 wikiaaa.example.com wikiaaa: Ran LDAP search for '(sAMAccountName=user1)' in 0,0016958713531494 seconds.Jl-mws (talk) 13:49, 5 August 2022 (UTC)
- please set $wgShowExceptionDetails=true; Bawolff (talk) 17:30, 5 August 2022 (UTC)
- For an LDAP User, I got
[7dfc41e030b5d57f84ec0e88] /index.php/Sp%C3%A9cial:PluggableAuthLogin MWException from line 89 of /var/lib/mediawiki/extensions/LDAPAuthentication2/src/PluggableAuth.php: The UsernameNormalizer for LDAPAuthentiation2 should be callable Backtrace: #0 /var/lib/mediawiki/extensions/LDAPAuthentication2/src/PluggableAuth.php(60): MediaWiki\Extension\LDAPAuthentication2\PluggableAuth->normalizeUsername() #1 /var/lib/mediawiki/extensions/PluggableAuth/includes/PluggableAuthLogin.php(36): MediaWiki\Extension\LDAPAuthentication2\PluggableAuth->authenticate() #2 /usr/share/mediawiki/includes/specialpage/SpecialPage.php(600): PluggableAuthLogin->execute() #3 /usr/share/mediawiki/includes/specialpage/SpecialPageFactory.php(635): SpecialPage->run() #4 /usr/share/mediawiki/includes/MediaWiki.php(307): MediaWiki\SpecialPage\SpecialPageFactory->executePath() #5 /usr/share/mediawiki/includes/MediaWiki.php(945): MediaWiki->performRequest() #6 /usr/share/mediawiki/includes/MediaWiki.php(548): MediaWiki->main() #7 /usr/share/mediawiki/index.php(53): MediaWiki->run() #8 /usr/share/mediawiki/index.php(46): wfIndexMain() #9 {main}- It works, with errors, for a local account Jl-mws (talk) 08:10, 8 August 2022 (UTC)
- @Jl-mws If you still run MediaWiki 1.35.4 then you run an outdated insecure software version. Please update to a supported version for your own safety. Malyacko (talk) 09:42, 8 August 2022 (UTC)
- Nope, it's a Debian version with backported security patches.
https://metadata.ftp-master.debian.org/changelogs//main/m/mediawiki/mediawiki_1.35.4-1+deb11u2_changelogJl-mws (talk) 10:07, 8 August 2022 (UTC)
Several points, for your information:
In the ldapprovider.json :
- the attributes requires lowercase despite their regular name ie 'displayName' for example
so ldapprovider.json (extract) become :
"usernameattribute": "samaccountname",
"realnameattribute": "displayname",
"emailattribute": "mail",
"grouprequest": "MediaWiki\\Extension\\LDAPProvider\\UserGroupsRequest\\UserMemberOf::factory",
"presearchusernamemodifiers": [ "spacestounderscores", "lowercase" ]
- the require.group require the "Full DN name" ie "CN=wikiaaa,CN=Users,dc=example,dc=com" even if short name are show and revolved by
LDAPProvider/maintenance/ShowUserGroups.php
I was using the short name for configuration clarity, it doesn't work Jl-mws (talk) 15:01, 9 August 2022 (UTC)
Some Page Popups do not show anymore after upgrading to mediawiki-1.37.4
Hi there, We use mediawiki to order our cooking recipes since 2019. I upgraded recently from mediawiki 1.35.1 to 1.37.4. Since then the Popups (using https://www.mediawiki.org/wiki/Extension:Popups – (2c2c6d3) 07:04, 26. Jul. 2022) of some pages are displayed. For many other Pages I get a popup window which gives the error message "Es gab ein Problem bei der Anzeige dieser Vorschau", which basically says: "There was a problem displaying this preview".
Any ideas? 964C2 (talk) 14:27, 5 August 2022 (UTC)
- Are there errors in web browser's dev console? In the network tab of the web browser dev console, are there requests to the api that result in 500?
- If you look in php error log, are there any errors? Bawolff (talk) 00:10, 6 August 2022 (UTC)
- @Bawolff: There are no entries in /var/log/apache/error.log at the moment.
- In the dev console I see not 500 error messages. Uploaded a screenshot here: https://up.picr.de/44131788ox.png
- There are 2 entries (the first 2) which say a 200 as a result and 2 other entries, where one is the initial request and the second shows, that a picture from the requested page is loaded afterwards ... 964C2 (talk) 08:01, 6 August 2022 (UTC)
How to make skin:Vector responsive?
MediaWiki 1.38.2 website without any non-core extensions or skins installed.
Skin:Vector not responsive by default but I understand from its webpage that there is an experimental way to make responsive.
1) Should I just add wgVectorResponsive = true; to LocalSettings.php?
2) Is this experimental option SEO friendly from your experience? Would you recommend not using it and preferring another approach to get screen-responsivness? 79.183.193.18 (talk) 19:23, 6 August 2022 (UTC)
- Adding
$wgVectorResponsive = true;to LocalSettings.php didn't make the website responsive. 79.183.193.18 (talk) 06:48, 7 August 2022 (UTC) - Maybe you need to upgrade Vector? Just a guess. Jonathan3 (talk) 18:29, 7 August 2022 (UTC)
- @Jonathan3
- What do you mean? My MediaWiki is already 1.38.2 which is latest. 79.183.193.18 (talk) 07:41, 12 August 2022 (UTC)
- I don't use Vector and have to upgrade my skin when I upgrade mediawiki. It sounds from what you said that this isn't relevant to you. Jonathan3 (talk) 09:02, 12 August 2022 (UTC)
- @Jonathan3 What do you mean by upgrade your skin?
- As far as I know, skins are upgraded (or not, it depends if there is anything in the skin to upgrade) whenever you upgrade MediaWiki. 79.183.193.18 (talk) 15:34, 12 August 2022 (UTC)
- See Bundled extensions and skins. Jonathan3 (talk) 16:33, 12 August 2022 (UTC)
- @Jonathan3 Of course, I meant only to core skins.
- Anyway I misunderstand the point you were trying to make even after visiting that link. 79.183.193.18 (talk) 17:18, 12 August 2022 (UTC)
- There are no core skins. Bawolff (talk) 21:03, 13 August 2022 (UTC)
- @Bawolff in great plea, your kind help. 79.183.193.18 (talk) 13:50, 13 August 2022 (UTC)
- I don't want to install MobileFrontend so I desperately seek a solution without it. 79.183.193.18 (talk) 13:51, 13 August 2022 (UTC)
- I dont know why $wgVectorResponsive isnt working. It works on wikipedia. Maybe you need the user preference.
- You could also try a different skin like Timeless or Minerva. Bawolff (talk) 21:03, 13 August 2022 (UTC)
- Awolff, what user preferenace? I want it for all users whatsoever. 2A03:C5C0:107C:AF99:0:0:6392:922E (talk) 12:42, 14 August 2022 (UTC)
- "Enable responsive mode" on Special:Preferences#mw-prefsection-rendering Malyacko (talk) 17:58, 14 August 2022 (UTC)
- Oh, I get it now.
- This "responsive mode" was already on all that time, but it is very far from giving the full scale responsiveness that Skin:Timeless gives or that the combination of Vector with Minerva_Neue gives. 79.183.193.18 (talk) 13:40, 19 August 2022 (UTC)
Font size for certain languages
For some reason, changing the language of the site changes the font-size as well.
What is responsible for this behavior, and how can this change be removed so that e.g. both English and Russian languages produce a text of the same size? Marx.FelipeForte (talk) 00:16, 7 August 2022 (UTC)
- It might depend on your browser config and be different between users. Some web browsers use different fonts for different languages.
- You can probably fix by setting a specific font in Mediawiki:common.css Bawolff (talk) 21:35, 7 August 2022 (UTC)
How to download xpdf for pdfinfo onto Mediawiki
I'm trying to use PdfHandler and I have convert and gs but not pdfinfo (which acccording to the page is why I'm getting a 0 x 0 pixels things). Apparently I have to download xpdf-utils from here: https://www.xpdfreader.com/download.html,
but I'm not sure about two things:
- Am I supposed to get XpdfReader or just Xpdf?
- If I download one of these how and where do I put it Mediawiki, meaning where do I put it in my file system, or if it is done through ssh what commands do I need to use?
I know that my hosting service is a Linux x86_64 system so if I need to get XpdfReader Linux 64.
Thanks Guillaume Taillefer (talk) 14:41, 7 August 2022 (UTC)
- If it helps, I used
sudo apt install poppler-utils - It's listed as an alternative so presumably I did it because I found it easier. Jonathan3 (talk) 18:25, 7 August 2022 (UTC)
After upgrade to 1.38 website is showing only blank white 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.
I upgraded from 1.35.7 to 1.38, ran the update script for database.
Then ran the website. on front page it showed 'deprecated...' message for 3-4 extensions and showed blank page. So I disabled the related extensions. Then again browsed the site. This time then I started gettign white blank page with no content at all. I looked at error log, it had nothing.
I changed the directory back to 1.37 for now. Please suggest what I should be looking and fixing.
Thanks Vikas Vikasnd (talk) 17:09, 7 August 2022 (UTC)
- Maybe remove or upgrade all extensions. Jonathan3 (talk) 17:29, 7 August 2022 (UTC)
- Maybe check LocalSettings.php for errors introduced when you got rid of the extensions. Jonathan3 (talk) 17:30, 7 August 2022 (UTC)
- Diff'ed the file and checked it, but nothing is different than comment mark on few extensions. Vikasnd (talk) 05:21, 8 August 2022 (UTC)
- Verify you have errors turned on in php.ini (see How to debug) Bawolff (talk) 21:32, 7 August 2022 (UTC)
- I have this turned on already. Vikasnd (talk) 05:13, 8 August 2022 (UTC)
- Manual:Errors and symptoms#You see a Blank Page Malyacko (talk) 09:42, 8 August 2022 (UTC)
- This did not help. There was still blank page.
- So I took off all extensions, still it was blank page.
- Then lastly I took off the 'foreground' skin that was being used. Then it started showing the page. I upgraded the skin, it looked better. Still figuring out other things, but this is how it was resolved. But there were no logs created to note whatever issue it was having. Would have helped a lot if there was some log written..
- Thanks to all of you. Vikasnd (talk) 18:05, 8 August 2022 (UTC)
- Good stuff. I like foreground but seem to have had some sort of problem with it during the last few MW upgrades. I'm pleasantly surprised it works on 1.38 :-) Jonathan3 (talk) 18:49, 8 August 2022 (UTC)
Infobox
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 created a template infobox in my wiki. If I insert the info box with brackets in the lemma, the template appears correctly. After inserting the data, I save the lemma, but the info box remains empty (no data). How do I have to program the template so that the template is inserted into the lemma (without using subst) and the info box filled with data becomes visible in the lemma after saving? LG Abrape Abrape (talk) 13:18, 8 August 2022 (UTC)
- I guess lemma is a word for page.
- Copy and paste your page (at least the part calling the template) and your template here and we'll see! Jonathan3 (talk) 18:47, 8 August 2022 (UTC)
| [[Datei:<Name>.png|thumb|center|<Berg>]] |
| Name = |
| Höhe in m ü. NHN = |
| Lage = |
| Gebirge = |
| Breitengrad = |
| Längengrad = |
| Typ = |
| Gestein = |
| Bauwerke = |
- Abrape (talk) 19:14, 8 August 2022 (UTC)
- Could you also copy and paste your page?
- In the template, you need to add the parameters. E.g. it might have
Name = {{{Name|}}}if your page has{{Templatename|Name=Joe Bloggs}}. - See Help:Templates#Parameters. Jonathan3 (talk) 22:40, 8 August 2022 (UTC)
- Done. Thank you for your help!
| [[Datei:<Name>.png|thumb|center|<Berg>]] |
| Name = |
| Höhe in m ü. NHN = |
| Lage = |
| Gebirge = |
| Breitengrad = |
| Längengrad = |
| Typ = |
| Gestein = |
| Bauwerke = |
- Abrape (talk) 13:36, 9 August 2022 (UTC)
- That looks like the Template page rather than the content page. Could you send both?
- It's surrounded by noinclude tags. That tells mediawiki not to include the text between the tags when the template is used. You could change them to includeonly and see what difference it makes.
- Also I wonder whether template parameters are case sensitive. I can't remember. Jonathan3 (talk) 14:03, 9 August 2022 (UTC)
- The copy of the side box has no reference here and therefore only Template:Testberg appears here. Sorry! Abrape (talk) 14:18, 9 August 2022 (UTC)
- I don't know what that means.
- If you mean how it appears on this website, don't worry - I can click "edit" to see what you copy/pasted.
- It would be good to see two things:
- 1. The name and content of the page containing the template code, e.g. Template:Testberg is the name and
<includeonly>...</includeonly>is the content. - 2. The content of the call to the template, e.g.
{{Testberg|name=Berlin}}. Jonathan3 (talk) 15:45, 9 August 2022 (UTC) - {{Infobox Test |NAME=Testberg |BILD= |BILDBESCHREIBUNG= |HÖHE=708 |HÖHE-BEZUG=DE-NHN |LAGE=[[Bayern]], [[Deutschland]] |GEBIRGE=[[Fichtelgebirge]] |BREITENGRAD=49/56/49/N |LÄNGENGRAD=12/08/10/E |REGION-ISO=DE-BY |TYP= |GESTEIN=Basalt |ALTER= |ERSTBESTEIGUNG= |BESONDERHEITEN= }} Abrape (talk) 16:23, 9 August 2022 (UTC)
Upload Files Error: Could not open lock file for "mwstore://local-backend/local-public/..."
Hello, I run MediaWiki using Ubuntu 20.04 and XAMPP.
In order to solve this upload problem, I set the owner of the "Images" directory to www-date and set the permission to 755, but the problem has not been solved.
I can't solve this problem anymore because I'm a beginner of web server operation. If there is any information related to this, please let me know.
Thank you. 멍한오리 (talk) 00:13, 9 August 2022 (UTC)
- For starters its www-data not www-date.
- XAMPP is a bit of an odd choice if using ubuntu. Normally you would use ubuntu's builtin package manager (e.g. apt).
- If using xampp, apache may be running as a different user and not www-data, so its possible that that is not the correct owner for the files. Bawolff (talk) 01:07, 9 August 2022 (UTC)
Special:Preferences Tabs
I just upgraded an instance from 1.35.2 to 1.38.2 (new install, database dump/restore). Most everything is working fine, except on Special:Preferences, none of the tabs are clickable.
I don't see any console errors, and nothing in the debug. I also tried adding #mw-prefsection-editing to the url, but it does nothing.
MediaWiki 1.38.2
PHP 7.4.30 (fpm-fcgi)
MariaDB 10.6.8-MariaDB
ICU 67.1
Lua 5.1.5 Tjbrace (talk) 18:49, 9 August 2022 (UTC)
- Seems that the issue was due to debugging being enabled. Tjbrace (talk) 00:05, 11 August 2022 (UTC)
Short URL not working as expected
I have an issue with short URLs, despite trying to follow the guide there.
My server is running Ubuntu 22.04.1 "jammy" and can be reached at https://ornans.wiki. I installed MediaWiki with apt install mediawiki and have the following software versions:
- dpkg -s mediawiki | grep Version returns Version: 1:1.35.6-1
- apache2 -v returns Server version: Apache/2.4.52 (Ubuntu)
- mysql --version returns mysql Ver 8.0.30-0ubuntu0.22.04.1 for Linux on x86_64 ((Ubuntu))
My MediaWiki install is located at /var/lib/mediawiki/ (so this is the location of my LocalSettings.php) and I made a symlink from /var/www/html to that folder (with the command ln -s /var/lib/mediawiki /var/www/html).
In my LocalSettings.php, wgScriptPath is set to "/mediawiki".
My Apache HTTPS config, located at /etc/apache2/sites-available/000-default.conf is:
<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /var/www/html
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
RewriteEngine on
RewriteCond %{SERVER_NAME} =www.ornans.wiki [OR]
RewriteCond %{SERVER_NAME} =ornans.wiki
RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent]
# Short URL for wiki pages
RewriteRule ^/?w(/.*)?$ %{DOCUMENT_ROOT}/mediawiki/index.php [L]
# Redirect / to Main Page
RewriteRule ^/*$ %{DOCUMENT_ROOT}/mediawiki/index.php [L]
</VirtualHost>
The HTTPS config, located at /etc/apache2/sites-available/000-default-le-ssl.conf is:
<IfModule mod_ssl.c>
<VirtualHost *:443>
any further virtual host explicitly.
ServerAdmin webmaster@localhost
DocumentRoot /var/www/html
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
Alias /w /var/lib/mediawiki/index.php
# Enable the rewrite engine
RewriteEngine On
# Redirect / to Main Page
RewriteRule ^/*$ %{DOCUMENT_ROOT}/mediawiki/index.php [L]
ServerName www.ornans.wiki
Include /etc/letsencrypt/options-ssl-apache.conf
ServerAlias ornans.wiki
SSLCertificateFile /etc/letsencrypt/live/www.ornans.wiki/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/www.ornans.wiki/privkey.pem
</VirtualHost>
</IfModule>
I would like my wiki to be accessed at w, without any browser URL rewriting. This means that I would like to write ornans.wiki/w/My_Page and it should show the page "My Page" while the URL displayed in the URL bar in the browser stays the same.
Does anyone know what I need to change in order for my MediaWiki install to work as I expect? 176.182.111.164 (talk) 22:25, 10 August 2022 (UTC)
- Your apache config looks fine.
- I think that your $wgArticlePath in LocalSettings.php is wrong. Try setting it to '/w/$1' Bawolff (talk) 22:13, 11 August 2022 (UTC)
- Thanks, I was sure I had tried that but it hadn't worked. Everything works fine now :) 176.164.252.138 (talk) 09:41, 16 August 2022 (UTC)
Recent number of edits
In "Page information", I can see "Recent number of edits". The interval for recent edits is the same as the maximum allowed value for "Days to show in recent changes" and "Days to show in watchlist" in Special:Preferences. The interval for recent edits is set 30 days on Wikimedia projects, and 5 years on translatewiki.net. Is it defined in $wgRCMaxAge, or another configuration setting? Vlad5250 (talk) 05:01, 11 August 2022 (UTC)
- I believe its set by the wgRCMaxAge setting. Bawolff (talk) 22:08, 11 August 2022 (UTC)
non capisco come installare Mediawiki, non capisco come si fa
per favore qualcuno mi aiuti 79.40.4.216 (talk) 07:15, 11 August 2022 (UTC)
- See Manual:Installing MediaWiki. If you have specific questions, please ask specific questions. Thanks! Malyacko (talk) 12:49, 11 August 2022 (UTC)
Login Page
Hello !!
I need to change the login page (so that the sidebar and the headerbar don't appear) but i can't find the page to change that. FamousHz1 (talk) 07:44, 11 August 2022 (UTC)
- Which version are you using? 156.8.246.10 (talk) 14:12, 11 August 2022 (UTC)
- It is 1.32.1 version FamousHz1 (talk) 08:50, 12 August 2022 (UTC)
- You can use css in mediawiki:common.css if $wgAllowSiteCSSOnRestrictedPages is set to true Bawolff (talk) 22:07, 11 August 2022 (UTC)
Upgraded 1.36.0 to 1.38.2 error in confirm account requests
I upgraded 1.36.0 to 1.38.2 and all went well, but I knew I would have to deal with a lot of spam account requests over the last few months. After the upgrade when I click "Confirm Account Requests" I get the error:
[YvX5Ud3_A3YQ4t5wzV-CqAAAAAk] 2022-08-12 06:55:13: Fatal exception of type "Error"
I hope someone can point me in the right direction here.
I'm running this on FreeBSD 13.1. Therotintheroot (talk) 07:11, 12 August 2022 (UTC)
- Set $wgShowExceptionDetails = true; and report back the more detailed error message Bawolff (talk) 09:38, 12 August 2022 (UTC)
- Site is warning me that this is harmful or unconstructive. If I'm not submitting this properly, please let me know. I do appreciate the help.
- [YvZ6fQayAYYB7SUqTjm6cQAAAAM] /wiki/index.php/Special:ConfirmAccounts Error: Undefined constant "DB_SLAVE"
- Backtrace:
- from /usr/local/www/apache24/data/wiki/extensions/ConfirmAccount/backend/ConfirmAccount.class.php(148)
- #0 /usr/local/www/apache24/data/wiki/extensions/ConfirmAccount/frontend/specialpages/actions/ConfirmAccount_body.php(209): ConfirmAccount::getOpenRequestCount(integer)
- #1 /usr/local/www/apache24/data/wiki/extensions/ConfirmAccount/frontend/specialpages/actions/ConfirmAccount_body.php(109): ConfirmAccountsPage->showQueues()
- #2 /usr/local/www/apache24/data/wiki/includes/specialpage/SpecialPage.php(671): ConfirmAccountsPage->execute(NULL)
- #3 /usr/local/www/apache24/data/wiki/includes/specialpage/SpecialPageFactory.php(1378): SpecialPage->run(NULL)
- #4 /usr/local/www/apache24/data/wiki/includes/MediaWiki.php(315): MediaWiki\SpecialPage\SpecialPageFactory->executePath(string, RequestContext)
- #5 /usr/local/www/apache24/data/wiki/includes/MediaWiki.php(912): MediaWiki->performRequest()
- #6 /usr/local/www/apache24/data/wiki/includes/MediaWiki.php(563): MediaWiki->main()
- #7 /usr/local/www/apache24/data/wiki/index.php(53): MediaWiki->run()
- #8 /usr/local/www/apache24/data/wiki/index.php(46): wfIndexMain()
- #9 {main} Therotintheroot (talk) 16:08, 12 August 2022 (UTC)
- Dont worry about the warning. Sometimes the spam filters are a bit aggressive.
- I think your version of ConfirmAccount is too old. Can you try updating it, to match the version of mediawiki you are using? Bawolff (talk) 20:50, 12 August 2022 (UTC)
- Thanks so much. I had completely forgotten that I had ever added anything third party. Therotintheroot (talk) 23:28, 12 August 2022 (UTC)
How to make Minerva Neue default mobile skin in 1.35 or greater?
MediaWiki 1.38.2.
I understand that since version 1.35 it is no longer required to install Extension:MobileFrontend to use Skin:Minerva Neue as a mobile-display skin.
It's not clear to me from the documentation how than to use Minerva_Neue as a mobile-display skin? How to enable it alongside Vector? 79.183.193.18 (talk) 11:42, 12 August 2022 (UTC)
- > I understand that since version 1.35 it is no longer required to install Extension:MobileFrontend to use Skin:Minerva Neue as a mobile-display skin.
- This is incorrect. It is not required to use it as a skin. It is still required if you want to use it as a mobile only skin. Bawolff (talk) 20:49, 12 August 2022 (UTC)
How to make MediaWiki mobile responsive?
Let's say I have installed the latest (currently 1.38.2) MediaWiki.
How do I make my website responsive to mobile displays? 79.183.193.18 (talk) 14:18, 12 August 2022 (UTC)
- This wasn't enough:79.183.193.18 (talk) 17:27, 12 August 2022 (UTC)
# Skin settings wfLoadSkin( 'Vector' ); $wgDefaultSkin = "vector"; wfLoadSkin( 'MinervaNeue' ); $wgDefaultMobileSkin = "minerva"; - Are you loading MobileFrontend? $wgDefaultMobileSkin = "minerva" wont do anything without it. Bawolff (talk) 20:48, 12 August 2022 (UTC)
- I didn't load it. I should load it.
- I thank you for clarifying that here:
- Project:Support desk/Flow/2022/08#h-How_to_make_Minerva_Neue_default_mobile_skin_in_1.35_or_greater?-20220812114200 79.183.193.18 (talk) 01:25, 13 August 2022 (UTC)
Please add MobileFrontend to core
I don't have a Phabricator account and most probably never have, so I can only use the current platform to share my voice to include Extension:MobileFrontend in the core.
I argue that since mobile responsiveness is a par excellence accessibility issue, it should be on the core. 79.183.193.18 (talk) 13:57, 13 August 2022 (UTC)
- Why? The skins already provide responsiveness, and they are included: Bundled extensions and skins Malyacko (talk) 16:57, 13 August 2022 (UTC)
- You can create a Phabricator account: Phabricator/Help#Creating your account Malyacko (talk) 16:57, 13 August 2022 (UTC)
- I avoid registering to websites if I don't have to, as a freedom principle.
- There are many problems with commenting from an account (and not anonymously) which this is not the correct forum to discuss.
- Skin:Vector is not responsive. 79.183.193.18 (talk) 20:31, 13 August 2022 (UTC)
- Skin:Vector isn't in core either.
- We are not adding MobileFrontend to core, but it will continue to be bundled in the tarball, which from a user perspective is almost the same thing.
- P.s. vector skin has an optional responsive mode. Timeless is another skin that is responsive, and you can use the minerva skin without mobile frontend if you so desire. Bawolff (talk) 20:55, 13 August 2022 (UTC)
How to add a "Contact us" button to Minerva_Neue mobile menu?
How to add a "Contact us" button to Minerva_Neue mobile menu?
By default, this menu only has the following links:
- Homepage
- RandomPage
- Login
- About WEBSITE
- Disclaimers 79.183.193.18 (talk) 14:00, 13 August 2022 (UTC)
- Bumping 79.183.193.18 (talk) 07:21, 15 August 2022 (UTC)
- Please do not bump after 30h over a weekend.
- Extension talk:MobileFrontend/2020#h-How_to_Customize_Mobile_Menu_Links-2020-07-27T20:33:00.000Z Malyacko (talk) 09:57, 15 August 2022 (UTC)
- @Malyacko
- Sorry, I don't understand, what is "30h over" here? 79.183.193.18 (talk) 12:06, 19 August 2022 (UTC)
- The 30 hours between your previous two comments. Humans sleep, humans are away from machines. Malyacko (talk) 15:07, 19 August 2022 (UTC)
- I don't understand why it matters, I would argue that in general it's legitimate to bump a post after 24 hours, and then after a week and then after a month. 79.183.193.18 (talk) 21:56, 19 August 2022 (UTC)
- No, 24 hours feels rude. Malyacko (talk) 09:11, 23 August 2022 (UTC)
How to remove /wiki/Main_page from homepage?
I would like to cleanup the frontpage by moving it from: mywebsite.com/wiki/Main_page to mywebsite.com.
Any help with .htaccess and warnings are greatly welcome! 109.172.152.247 (talk) 18:09, 13 August 2022 (UTC)
- Set $wgMainPageIsDomainRoot = true;
- You need some rewrite rules to ensure the domain root is served by mediawiki. Bawolff (talk) 20:51, 13 August 2022 (UTC)
Weird behavior
I posted before how I couldn't get any background images to work, even if placed in the common css. How I've found that the extension Extension:WikidataPageBanner also doesn't work. It seems my wiki is not allowing me to place any image into the background. Can't think of what's causing this. Maybe a css file? Thanks
notes:
Version 1.38.2
no error messages say anything about the extension Christharp (talk) 18:59, 13 August 2022 (UTC)
- Can you include link to your wiki and what css you are using to make the background. Bawolff (talk) 20:49, 13 August 2022 (UTC)
- Hi, unfortunately it's on a local host. My background image css is: .page-Main_Page #content { background: url(/foo/bar/someimage.png); }, except, of course, the url is a real one. Christharp (talk) 17:41, 16 August 2022 (UTC)
What size should a skin:Vector logo get?
Say I have a raster image (png/jpg) or a vector image (svg/eps) which I use as a logo on a website with Skin:Vector, what size should I give it and where should I give it? When resizing the image file itself or in mediawiki:Common.css? 79.183.193.18 (talk) 20:41, 13 August 2022 (UTC)
- See Manual:$wgLogos Bawolff (talk) 01:17, 14 August 2022 (UTC)
- @Bawolff this manual page is very unclear to me.
- Is there something I should follow there in particular? 79.183.193.18 (talk) 07:21, 15 August 2022 (UTC)
- "where should I give it?"
- I think ideally you would resize the image(s) before uploading.
- Though I think some skins resize images to fit. Jonathan3 (talk) 08:34, 15 August 2022 (UTC)
Does MediaWiki support with eps image files?
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 graphic design agency brought me a logo image in .eps file format.
I have tried to upload this image and relate it from LocalSettings.php but no logo appears in the website.
This brings me to ask if MediaWiki even support .eps image files?
It does support .svg so why not support .eps? 79.183.193.18 (talk) 20:45, 13 August 2022 (UTC)
- For the logo, it supports whatever web browsers support, which includes svg but not eps. Bawolff (talk) 20:48, 13 August 2022 (UTC)
- Thanks, Bawolff.
- I have already contacted the agency to ask for a
.svgfile. - Please mark this thread as solved. 79.183.193.18 (talk) 20:57, 13 August 2022 (UTC)
Problem Visual Editor Error 500
I just can't use the extension Visual Editor. I always get the error Error contacting the Parsoid/RESTBase server (HTTP 500).
I have already tried a lot to find a solution but I just can't get any further.
Can someone tell me what the Parsoid/RESTBase server is?
I just can't find a solution to the problem
I have already deactivated and deactivated again the plugin VisualEditor several times in the LocalSettings.
What more info do you guys need? Paul Machtenberg (talk) 21:14, 13 August 2022 (UTC)
- Can your webserver send http connections to itself? Bawolff (talk) 00:29, 14 August 2022 (UTC)
- I don't know. How can i find out?
- The Wiki Page is launching on a https Connection Paul Machtenberg (talk) 08:06, 14 August 2022 (UTC)
An error occurred: The configuration setting 'wgCaptchaClass' was already set by MediaWiki core or another extension, and cannot be set again by ReCaptchaNoCaptcha.
I have an error when trying to update old tables for new one. How to solve this? PrometheusAla (talk) 06:32, 14 August 2022 (UTC)
- Installation stopped, how to resume it? PrometheusAla (talk) 06:35, 14 August 2022 (UTC)
- it sounds like either you need to update your extensions or perhaps there is some sort of extension config in your LocalSettings.php that needs to be updated for the new version of the extension. Bawolff (talk) 06:51, 14 August 2022 (UTC)
- Which? And how? Please help PrometheusAla (talk) 07:41, 14 August 2022 (UTC)
- Database doesn't contain such setting as wgCaptchaClass - only in LocalSetinngs file. PrometheusAla (talk) 07:47, 14 August 2022 (UTC)
- This isn't a database error, so that is expected. Bawolff (talk) 07:49, 14 August 2022 (UTC)
- Can you help? PrometheusAla (talk) 07:57, 14 August 2022 (UTC)
- What to do or check? PrometheusAla (talk) 07:57, 14 August 2022 (UTC)
- This isn't a database error, so that is expected. Bawolff (talk) 07:49, 14 August 2022 (UTC)
- Is ConfirmEdit extension the right version for your version of mediawiki? Is your config in line with what is suggested at https://www.mediawiki.org/wiki/Extension:ConfirmEdit#ReCaptcha_%28NoCaptcha%29 Bawolff (talk) 07:48, 14 August 2022 (UTC)
- I read about v2 version. It's correct. I have old version of WikiMedia 1.26 - now trying to upgrade it for 1.38. How to step-up this option in update process? It's something in database - stopped at DB updating process.
- https://ibb.co/8X66F4v - error screen PrometheusAla (talk) 07:57, 14 August 2022 (UTC)
- wfLoadExtensions([ 'ConfirmEdit', 'ConfirmEdit/ReCaptchaNoCaptcha' ]);
- $wgCaptchaClass = 'ReCaptchaNoCaptcha';
- $wgReCaptchaSiteKey = '****';
- $wgReCaptchaSecretKey = '****';
- When delete this lines from LocalSettings apeeared new error
- Modifying workflow_id field of table flow_workflow...
- An error occurred:
- Error 1171: All parts of a PRIMARY KEY must be NOT NULL; if you need NULL in a key, use UNIQUE instead (localhost)
- Function: Wikimedia\Rdbms\Database::sourceFile( C:\wamp64\www\wiki\extensions\Flow/db_patches/patch-88bit_uuids.sql )
- Query: ALTER TABLE `bahaiwiki_flow_topic_list`
CHANGE topic_list_id topic_list_id binary(11) not null,CHANGE topic_id topic_id binary(11) default nullPrometheusAla (talk) 08:02, 14 August 2022 (UTC)- Should I delete Recaptcha settings from LocalSettings? PrometheusAla (talk) 08:11, 14 August 2022 (UTC)
- That or you should update the extension and fix any config issues if present. Bawolff (talk) 08:19, 14 August 2022 (UTC)
- This error (the workflow_id one) is probably caused by having the wrong version of flow/StructuredDiscussions. If you are updating to 1.38 of mediawiki, you also have to update all extension files to the 1.38 version
- [Underlying issue is fixed in commit 2f61ff87f03705a3f52d51fb3534a2bb2a977161] Bawolff (talk) 08:17, 14 August 2022 (UTC)
I have clean installation of 1.38 Wikimedia and 1.24 DB dump and files
How to correctly import old data to new installation? Old installation was rewritten by mistake. PrometheusAla (talk) 17:53, 14 August 2022 (UTC)
- Also old LocalSettings.php file. What updates should implement to update it. PrometheusAla (talk) 17:54, 14 August 2022 (UTC)
- You don't. You have to take the sql dump, import it into a db, and then run update.php. Bawolff (talk) 19:29, 14 August 2022 (UTC)
- I did it... but it still doesn't work ( PrometheusAla (talk) 19:31, 14 August 2022 (UTC)
- Please provide clear steps, and explain what "doesn't work", without any paraphrasing. Malyacko (talk) 19:49, 14 August 2022 (UTC)
Permanent redirect
I have an error with permanent redirect - 301 redirect from main page. Where to see to find problem? 1.38 version PrometheusAla (talk) 18:20, 14 August 2022 (UTC)
- What is the error message? Bawolff (talk) 19:27, 14 August 2022 (UTC)
- Nothing ( also in php logs. Or I should turn on display errors somewhere? PrometheusAla (talk) 19:30, 14 August 2022 (UTC)
- If there is no error, what is the problem you are encountering. Bawolff (talk) 20:30, 14 August 2022 (UTC)
- permanent redirect - 301 redirect PrometheusAla (talk) 08:10, 15 August 2022 (UTC)
- 301 Moved Permanently and cycled page reload PrometheusAla (talk) 08:12, 15 August 2022 (UTC)
- Probably an issue with rewrite rules. Bawolff (talk) 08:59, 15 August 2022 (UTC)
- How to check it? Or how to solve? PrometheusAla (talk) 10:58, 15 August 2022 (UTC)
- Web server logs and web server documentation. Malyacko (talk) 11:00, 15 August 2022 (UTC)
Organizing categories with RegEx / JWB
Hello, I'm currently working on a mid-sized wiki on Fandom and their categories are not in a consistent order. With regex I am planning to organize in a custom manner working with sub/super categories on the wiki. I am thinking with using patterns and groups but I can't seem to work it out.
If you could help out in making a sample to organize categories it would be much appreciated. 2601:282:117F:5960:ACE2:2E0A:3489:8A4A (talk) 04:34, 15 August 2022 (UTC)
Wiki login causes BadMethodCallException
I have a new installation of Mediawiki 1.38 with MariaDB 10.8 and php 7.4.30. If i run the install and set it to a private wiki, when you attempt to log in (after entering name and password), you get an error [ca59474baf38d711fbded9e1] 2022-08-15 12:34:53: Fatal exception of type "BadMethodCallException". I'm sorry but i have no idea how to troubleshoot this.
If i set the wiki so it doesn't require login, it works as expected, with no issues.
Any help would be greatly appreciated. Bernie kra (talk) 12:38, 15 August 2022 (UTC)
- Can you add $wgShowExceptionDetails=true; to LocalSettings.php to give a more detailed error message? Bawolff (talk) 12:43, 15 August 2022 (UTC)
- @Bawolff, Thank you so much. Adding the details pointed me right to the cause. It's working now. I'm extremely grateful. Bernie kra (talk) 12:51, 15 August 2022 (UTC)
JS title-replacement code doesn't work as it should
On my creative-venture wiki, I have just reworked a JS segment from my days on Referata that replaces a namespace word with a page type-turned-pseudo-namespace. In my case, the target is the Morpheme NS, which should identify pages in its list as roots ("Root") or affixes ("Affix"). What I came up with, without breaking the rest of my Common.js:
$(function() {
var s = document.querySelector('.ns-3036 #firstHeadingTitle').innerHTML;
s = s.replace("Morpheme", function() {
if(s.match(/(^-|-$)/)) {
"Affix"
} else {
"Root"
}
});
document.querySelector('.ns-3036 #firstHeadingTitle').innerHTML = s;
}());Tried it out a while ago, but no change occurs; I was 80% sure I'd do it right. (Trust me, JS is not really one of my strengths, and I tend to learn by example.)
To @Bawolff How do I go about repairing the embedded function() here?
(MW 1.38.2; filed via Monobook)
--Slgrandson (talk) 15:07, 15 August 2022 (UTC)
- Pretty sure it should be #firstHeading not #firstHeadingTitle.
- Also i would generally reccomend using innerText over innerHTML when possible. This particular example looks safe, but its very easy to accidentally create a XSS issue when using innerHTML. Bawolff (talk) 20:03, 15 August 2022 (UTC)
- Oh, i guess also the inner s.match wont get prefixes because its testing whether the whole title including namespace starts ir ends with -, not just the part after the colon. Bawolff (talk) 20:22, 15 August 2022 (UTC)
- Retooled the middle portion minutes ago as:
$(function() { var s = document.querySelector('.ns-3036 #firstHeadingTitle').innerText; s = s.replace("Morpheme", function(pseudo) { if(s.match(/(:-|-$)/)) { "Affix" } else { "Root" } }); document.querySelector('.ns-3036 #firstHeadingTitle').innerText = s; }());- ...only now "undefined:Title" appears instead of "Root:Title". --Slgrandson (talk) 22:39, 15 August 2022 (UTC)
- Oh, you are also missing return. E.g. return "Affix"; and return "Root"; Bawolff (talk) 23:12, 15 August 2022 (UTC)
- On the other hand, I came up with this solution myself (which actually works):
... if (s.match(/(:-|-$)/)) { s = s.replace("Morpheme","Affix") } else { s = s.replace("Morpheme","Root") }; ...- --Slgrandson (talk) 23:16, 15 August 2022 (UTC)
Update from 1.27 to 1.35
I took over maintenance of an internal wiki at my employer. I tried to update from 1.27 to 1.25 in one step, but get errors like this:
ailed to populate content table archive row batch starting at 91 due to exception: Wikimedia\Rdbms\DBQueryError: Error 1062: Duplicate entry '91-1' for key 'PRIMARY' (localhost)
Function: PopulateContentTables::populateContentTablesForRowBatch
Query: INSERT INTO `slots` (slot_revision_id,slot_role_id,slot_content_id,slot_origin) VALUES ('91',1,'205503','91'),('91',1,'205503','91'),('92',1,'205504','92'),('92',1,'205504','92'),('93',1,'205505','93'),('219',1,'205506','219'),('220',1,'205507','220'),('230',1,'205508','230'),('231',1,'205509','231'),('232',1,'205510','232'),('232',1,'205510','232'),('233',1,'205511','233'),('240',1,'205512','240'),('240',1,'205512','240'),('257',1,'205513','257'),('257',1,'205513','257'),('264',1,'205514','264'),('277',1,'205515','277'),('277',1,'205515','277'),('282',1,'205516','282'),('283',1,'205517','283')
in /www/common/mediawiki-1.35.7/includes/libs/rdbms/database/Database.php:1700
Stack trace:
#0 /www/common/mediawiki-1.35.7/includes/libs/rdbms/database/Database.php(1684): Wikimedia\Rdbms\Database->getQueryException()
#1 /www/common/mediawiki-1.35.7/includes/libs/rdbms/database/Database.php(1659): Wikimedia\Rdbms\Database->getQueryExceptionAndLog()
#2 /www/common/mediawiki-1.35.7/includes/libs/rdbms/database/Database.php(1228): Wikimedia\Rdbms\Database->reportQueryError()
#3 /www/common/mediawiki-1.35.7/includes/libs/rdbms/database/Database.php(2344): Wikimedia\Rdbms\Database->query()
#4 /www/common/mediawiki-1.35.7/includes/libs/rdbms/database/Database.php(2324): Wikimedia\Rdbms\Database->doInsert()
#5 /www/common/mediawiki-1.35.7/includes/libs/rdbms/database/DBConnRef.php(68): Wikimedia\Rdbms\Database->insert()
#6 /www/common/mediawiki-1.35.7/includes/libs/rdbms/database/DBConnRef.php(369): Wikimedia\Rdbms\DBConnRef->__call()
#7 /www/common/mediawiki-1.35.7/maintenance/populateContentTables.php(328): Wikimedia\Rdbms\DBConnRef->insert()
#8 /www/common/mediawiki-1.35.7/maintenance/populateContentTables.php(232): PopulateContentTables->populateContentTablesForRowBatch()
#9 /www/common/mediawiki-1.35.7/maintenance/populateContentTables.php(99): PopulateContentTables->populateTable()
#10 /www/common/mediawiki-1.35.7/includes/installer/DatabaseUpdater.php(1460): PopulateContentTables->execute()
#11 /www/common/mediawiki-1.35.7/includes/installer/DatabaseUpdater.php(554): DatabaseUpdater->populateContentTables()
#12 /www/common/mediawiki-1.35.7/includes/installer/DatabaseUpdater.php(517): DatabaseUpdater->runUpdates()
#13 /www/common/mediawiki-1.35.7/maintenance/update.php(181): DatabaseUpdater->doUpdates()
#14 /www/common/mediawiki-1.35.7/maintenance/doMaintenance.php(107): UpdateMediaWiki->execute()
#15 /www/common/mediawiki-1.35.7/maintenance/update.php(253): require_once('/www/common/med...')
#16 {main}
- Am I correct in assuming the step 1.27 -> 1.35 is too big? Can you advise me whicversion h steps I should take?
- Before trying again, I restore my DB backup, righjt?
Thanks for your advise 2A02:6D40:2C07:2001:726D:148D:2347:36B1 (talk) 18:22, 15 August 2022 (UTC)
- Normally that would not be too big a step (you would get explicit error if its too big) Bawolff (talk) 19:53, 15 August 2022 (UTC)
- Thank you!
- I examined the DB using phpmyadmin and manually deleted some entries in table archive with duplicate id. After that, the update script succeeded. 2A02:6D40:2C07:2001:726D:148D:2347:36B1 (talk) 09:38, 16 August 2022 (UTC)
error
i installed 1.35 and uploaded localsettings.php but it gives me an error when visiting it Aeonjupiter (talk) 20:01, 15 August 2022 (UTC)
- Can you tell us what the error is? (Preferably set $wgShowExceptionDetails=true; at bottom of LocalSettings.php to include detailed error messages) Bawolff (talk) 20:20, 15 August 2022 (UTC)
Userpage link preview
I am not sure if this is the right place, but I am curious regarding this. In the English Wikipedia, when I hold my pointer on the link saying userpage, the preview says 'View the user page". But when done on the adjacent talkpage link, it says "discuss improvements to the content page". But a user talk page is for discussing something with the user, whereas improveents to the content page is for other namespaces. Kpddg (talk) 14:36, 16 August 2022 (UTC)
My quotes are broken
https://бахаи.kz/index.php?title=%D0%97%D0%B0%D0%B3%D0%BB%D0%B0%D0%B2%D0%BD%D0%B0%D1%8F_%D1%81%D1%82%D1%80%D0%B0%D0%BD%D0%B8%D1%86%D0%B0 - can you help? PrometheusAla (talk) 18:35, 16 August 2022 (UTC)
- Install extension:ParserFunctions Bawolff (talk) 20:26, 16 August 2022 (UTC)
- It already installed PrometheusAla (talk) 07:17, 17 August 2022 (UTC)
- it is not. It would be listed at https://xn--80aab4a4d.kz/index.php?title=%D0%A1%D0%BB%D1%83%D0%B6%D0%B5%D0%B1%D0%BD%D0%B0%D1%8F:%D0%92%D0%B5%D1%80%D1%81%D0%B8%D1%8F if it was. Bawolff (talk) 11:51, 17 August 2022 (UTC)
- Thanks! I saw extension in its folder! But it wasn't enabled in LS file. PrometheusAla (talk) 10:24, 18 August 2022 (UTC)
- Can you help also about Flow - it shows error {"flow-workflow":"vd0hqd6z5q85kr9j"} - and no comments? Even by link above PrometheusAla (talk) 10:26, 18 August 2022 (UTC)
- Sounds like a content model issue. They may have been imported incorrectly or imported before the flow extension was enabled.
- i think the easiest way to fix is to reimport after being sure flow is enabled. Otherwise im not sure what to do short of mucking around in db. Bawolff (talk) 10:44, 18 August 2022 (UTC)
- Anybody? ) Or may be someone already met such error? PrometheusAla (talk) 05:29, 19 August 2022 (UTC)
- https://бахаи.kz/index.php?title=%D0%9E%D0%B1%D1%81%D1%83%D0%B6%D0%B4%D0%B5%D0%BD%D0%B8%D0%B5:%D0%90%D0%B1%D0%B4%D1%83%D0%BB-%D0%91%D0%B0%D1%85%D0%B0#Test - at this page no error, but don't show the form to comment or create topic... PrometheusAla (talk) 14:44, 20 August 2022 (UTC)
- ? PrometheusAla (talk) 14:43, 22 August 2022 (UTC)
SVG preview rendering issue
I tried to include *SVG into list of allowed/preferred extensions for uploading files.
using
$wgSVGConverter = 'ImageMagick';
Also increased the virtual memory with:
$wgMaxShellMemory = 307200;
But i cannot solve the following issues:
Fehler beim Erstellen des Vorschaubildes: /mnt/web3xx/c0/90/5xx0xx0/htdocs/wiki/vendor/wikimedia/shellbox/src/Command/limit.sh: line 84: ulimit: file size: cannot modify limit: Operation not permitted convert: attempt to perform an operation not allowed by the security policy `MVG' @ error/constitute.c/IsCoderAuthorized/422. convert: no images defined `PNG:/tmp/transform_800b53f7d312.png' @ error/convert.c/ConvertImageCommand/3229.
Any ideas? 109.43.112.130 (talk) 19:03, 16 August 2022 (UTC)
- I added
- $wgMaxShellFileSize = unlimited;
- and the message reduces to:
- Fehler beim Erstellen des Vorschaubildes: convert: attempt to perform an operation not allowed by the security policy `MVG' @ error/constitute.c/IsCoderAuthorized/422. convert: no images defined `PNG:/tmp/transform_e47f5eb04c6d.png' @ error/convert.c/ConvertImageCommand/3229.
- Any ideas for that issue? 109.43.112.130 (talk) 20:13, 16 August 2022 (UTC)
- Try adjusting $wgMaxShellFileSize. It sounds like the issue is your host already sets a max, and you get an error when mediawiki tries to set it to something bigger than max, so try setting it to something smaller. Bawolff (talk) 20:24, 16 August 2022 (UTC)
- thanks, i tried it but that didn't have any effects. I think this is a security policy problem of ImageMagick, i cannot change (managed server).
- I solved it using the NativeSvgHandler extension.
- Extension:NativeSvgHandler - MediaWiki 109.43.112.130 (talk) 20:56, 16 August 2022 (UTC)
- Ah you're right. The second error is due to image magick config. Bawolff (talk) 21:32, 16 August 2022 (UTC)
Only main page loads behind nginx reverse proxy.
Hello,
I migrated my mediawiki site to a behind an nginx reverse proxy. I am successfully able to load the main page with its images and css, however any link that I click will reload the page with the new URL in the address bar but the page content is just the main page again. the only page that media wiki will show me is the main page regardless of the URL specified. I'll share my configurations below and my software versions are MediaWiki: 1.37.1 PHP: 8.1.2 running on Ubuntu 22.04.1 LTS with the site hosted on Apache. Hopefully someone can spot my mistake.
Thank's in advance!
From LocalSettings.php:
$wgScriptPath = "/hpwiki";
$wgResourceBasePath = $wgScriptPath;
$wgServer = "https://local.example.com";
From nginx:
# Local Pass
server {
listen 443 ssl;
server_name local.example.com;
ssl_certificate /etc/ssl/certs/example.pem;
ssl_certificate_key /etc/ssl/certs/example.key;
ssl_session_cache builtin:1000 shared:SSL:10m;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_ciphers HIGH:!aNULL:!eNULL:!EXPORT:!CAMELLIA:!DES:!MD5:!PSK:!RC4;
ssl_prefer_server_ciphers on;
access_log /var/log/nginx/local_example_access.log;
# Root Redirect
location / {
return 301 https://example.com;
}
# Wiki Pass
location /wiki/ {
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_pass http://localhost:8082/;
proxy_read_timeout 90;
}
}
From the Apache VirtualHost file:
<VirtualHost *:8082>
ServerName example
ServerAdmin webmaster@localhost
DocumentRoot /var/www/example
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost> 99.111.170.191 (talk) 19:27, 16 August 2022 (UTC)
- My mistake. For the sake of consistency in the examples I gave, $wgScriptPath = "/wiki"; in LocalSettings.php 99.111.170.191 (talk) 19:32, 16 August 2022 (UTC)
- Is it intentional you are doing proxy_pass http://localhost:8082/; instead of proxy_pass http://localhost:8082;
- It is hard to know from what you posted of your apache setup, which would be correct.
- Beyond that, i would suggest looking at your nginx and apache logs for the urls that dont work and see if they are what you expect. Bawolff (talk) 20:21, 16 August 2022 (UTC)
mediawiki api not working
Whenever I am trying to access any of my api, i am getting error which was not before. So, I tried to access http://localhost/mediawiki/index.php/.
I am getting the following error
{ "error": { "code": "internal_api_error_ParseError", "info": "[792875debeabf9a5e89b8267] Exception caught: syntax error, unexpected '*', expecting function (T_FUNCTION) or const (T_CONST)", "errorclass": "ParseError", "*": "ParseError at C:\\xampp\\htdocs\\mediawiki\\extensions\\praise\\praiseapi.php(56)\nfrom C:\\xampp\\htdocs\\mediawiki\\extensions\\praise\\praiseapi.php(56)\n#0 [internal function]: AutoLoader::autoload(string)\n#1 C:\\xampp\\htdocs\\mediawiki\\vendor\\wikimedia\\object-factory\\src\\ObjectFactory\\ObjectFactory.php(244): spl_autoload_call(string)\n#2 C:\\xampp\\htdocs\\mediawiki\\vendor\\wikimedia\\object-factory\\src\\ObjectFactory\\ObjectFactory.php(150): Wikimedia\\ObjectFactory\\ObjectFactory::getObjectFromSpec(array, array)\n#3 C:\\xampp\\htdocs\\mediawiki\\includes\\api\\ApiModuleManager.php(183): Wikimedia\\ObjectFactory\\ObjectFactory->createObject(array, array)\n#4 C:\\xampp\\htdocs\\mediawiki\\includes\\api\\ApiModuleManager.php(155): ApiModuleManager->instantiateModule(string, array)\n#5 C:\\xampp\\htdocs\\mediawiki\\includes\\api\\ApiBase.php(610): ApiModuleManager->getModule(string)\n#6 C:\\xampp\\htdocs\\mediawiki\\includes\\api\\ApiBase.php(1839): ApiBase->getModuleFromPath(string)\n#7 C:\\xampp\\htdocs\\mediawiki\\includes\\api\\ApiHelp.php(467): ApiBase->getFinalParamDescription()\n#8 C:\\xampp\\htdocs\\mediawiki\\includes\\api\\ApiHelp.php(180): ApiHelp::getHelpInternal(DerivativeContext, array, array, array)\n#9 C:\\xampp\\htdocs\\mediawiki\\includes\\api\\ApiHelp.php(70): ApiHelp::getHelp(DerivativeContext, array, array)\n#10 C:\\xampp\\htdocs\\mediawiki\\includes\\api\\ApiMain.php(1874): ApiHelp->execute()\n#11 C:\\xampp\\htdocs\\mediawiki\\includes\\api\\ApiMain.php(853): ApiMain->executeAction()\n#12 C:\\xampp\\htdocs\\mediawiki\\includes\\api\\ApiMain.php(824): ApiMain->executeActionWithErrorHandling()\n#13 C:\\xampp\\htdocs\\mediawiki\\api.php(90): ApiMain->execute()\n#14 C:\\xampp\\htdocs\\mediawiki\\api.php(45): wfApiMain()\n#15 {main}" } } Misty-2409 (talk) 21:27, 16 August 2022 (UTC)
- Most likely means that mediawiki's files were corrupted. I would suggest redownloading them. Bawolff (talk) 22:14, 16 August 2022 (UTC)
Help Working Through Update Issues (There will be a lot)
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 been working on trying to update my private wiki over the last few months. Upgrading the existing installation has proven problematic. I got it up to version 1.31.16 before I threw in the towel and tried a different approach. For some reference, my wiki has been around for ~15 years, and used MediaWiki the entire time, starting around version 1.6 (maybe 1.16) I think. One of the things I did fairly early on was create a custom skin for it (it took close to a year for me to get it 'perfect'). I barely know php, and haven't used my only slightly better html + css know-how in years.
To try and work around the updating problems I'd created a separate installation of 1.38.2 via Softalicious, and done a database copy/import. Amazingly, that seems to have worked so far, but my skin is 'old' and I honestly don't know what to do to get it up to snuff. Current issue is that BaseTemplate::getAfterPortlet was depreciated and I do not understand the documentation trying to explain what method to change it to. I would really prefer not to try and rebuild my skin from scratch if at all possible...
The line referenced in 'lcars.template.php':
<?php $this->getAfterPortlet( 'cactions' ); ?>
There are 5 instances in my skin file that use this same method: 'tb', 'lang', $bar, and 'search' Lord Trekie (talk) 03:11, 17 August 2022 (UTC)
- A quick fix would be:
$this->getSkin()->getAfterPortlet( 'cactions' );
- But in general skins have changed quite a bit. They now generally should extend SkinMustache instead of BaseTemplate and use mustache templates to render the skin layout, and hook into the various. This is how skins like vector, monobook, skincitizen, even older skins like cologneblue, modern
- I think https://github.com/StarCitizenTools/mediawiki-skins-Citizen is actually a pretty good example to look at, as it is a fairly elaborate but also 3rd party skin.
- Rewriting it with those techniques is probably quite involved for you, but will guarantee it will be able to be used for another few years most likely. —TheDJ (Not WMF) (talk • contribs) 20:14, 17 August 2022 (UTC)
- I got those changed, thanks very much! While that Star Citizen skin is nice, it's not really what I'm looking for. (This is what mine is supposed to look like: http://tf-575.com/)
- Unfortunately now there's (still) an error with a 'Call to undefined method Sanitizer::escapeId()' and I'm not seeing this specific usage in the documentation, depreciated or not. :'(
function customBox( $bar, $cont ) {$portletAttribs = array('class' => 'generated-sidebar portlet','id' => Sanitizer::escapeId( "p-$bar" ),'role' => 'navigation');...Lord Trekie (talk) 05:54, 19 August 2022 (UTC)
Cirrus Search on private wikis
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 installed several wikis with the CirrusSearch extension. However, when I try to do a search on a private wiki, an error message appears saying:
An error occured during your search: We cannot complete the search due to a temporary problem. Please try again later".
What can I do, or how can I config the LocalSettings.php to make CirrusSearch run on private wikis?
Kind regards,
Alexander Blum Ablum010777 (talk) 09:57, 17 August 2022 (UTC)
- Try enabling mediawiki debug log to see if there are any helpful error messages. Bawolff (talk) 11:48, 17 August 2022 (UTC)
- I already did that, it shows nothing. Ablum010777 (talk) 11:53, 17 August 2022 (UTC)
- I found the error myself: I had to set the locale to "en_US.utf8" in the LocalSettings.php. After that the CIrrusSearch extension worked smoothly. Ablum010777 (talk) 12:29, 23 August 2022 (UTC)
After the installation is successful, the wiki pages does not display any skin/theme.
After the installation is successfully completed, my wiki page does not display any skin, everything is blank and all plain text.
I've tried checking LocalSettings.php , but I'm sure I'm doing exactly what the installation process requires and there is no error message.
Is there any kind person who can help me? Thanks a lot.
Thanks everyone for the patience with non-native English speaker. :D Mantohu (talk) 10:02, 17 August 2022 (UTC)
- MediaWiki show no error. But the error generated in the Apache error log.
[Wed Aug 17 10:37:55.837118 2022] [proxy_fcgi:error] [pid 1208:tid 140197479880448] [client xxx.xx.xx.xxx(myip):60967] Premature end of script headers: load.php, referer: https://localhost/w/index.php?title=%E9%A6%96%E9%A0%81[Wed Aug 17 10:37:55.837203 2022] [proxy_fcgi:error] [pid 1208:tid 140197479880448] [client xxx.xx.xx.xxx(myip):60967] AH01070: Error parsing script headers, referer: https://localhost/w/index.php?title=%E9%A6%96%E9%A0%81[Wed Aug 17 10:37:55.837213 2022] [proxy_fcgi:error] [pid 1208:tid 140197479880448] (22)Invalid argument: [client xxx.xx.xx.xxx(myip):60967] AH01075: Error dispatching request to : , referer: https://localhost/w/index.php?title=%E9%A6%96%E9%A0%81Mantohu (talk) 10:18, 17 August 2022 (UTC)- Do you have php error logging enabled? (See How to debug).
- This could also potentially mean that php is segfaulting for some reason, which can be hard to figure out what is going on, and often easiest fixed by using a different version of php. Bawolff (talk) 11:47, 17 August 2022 (UTC)
How to get the following information using MySQL?
I need to get these info from my Wiki:
list of pages in the wiki with username of who created the page, username of who made the last change, timestamps for these two actions, and text length.
I can't figure out in which way to join the users and the timestamps to the page_title and page_len columns.
Could anybody help me in building the correct query please? 195.226.23.92 (talk) 10:25, 17 August 2022 (UTC)
- How about something like:
select page_namespace, page_title, (select actor_name from revision inner join actor on rev_actor = actor_id where rev_page = page_id order by rev_timestamp asc limit 1) 'creator', (select TIMESTAMP(rev_timestamp) from revision where rev_page = page_id order by rev_timestamp asc limit 1) 'creation date', a1.actor_name 'last editor',timestamp(r1.rev_timestamp) 'last edit date' from page inner join revision r1 on r1.rev_id = page_latest inner join actor a1 on actor_id = r1.rev_actorBawolff (talk) 02:55, 18 August 2022 (UTC)- Wow! Thanks you so much for the effort!! That's an impressive query.
- I copy-pasted this query since I do not understand it enough to be able to modify it if needed, and I receive the error:$
- ERROR 1054 (42S22): Unknown column 'rev_actor' in 'on clause' 195.226.23.92 (talk) 06:55, 18 August 2022 (UTC)
- Just to confirm, you are using a new-ish version of mediawiki (rev_actor was added in 1.35 so you need at least that). And be sure that you are currently using the correct DB.
- I did test it, and it seems to work - https://quarry.wmcloud.org/query/66716 (That link has syntax highlighting which might make the query easier to understand).
- The basic gist of the query, is we're selecting all the pages in the page table. We are joining the revision table using the page_latest field to the rev_id field to get the latest revision. From there we get the rev_timestamp for the last edit date, and we join on actor to turn rev_actor into an actual username.
- For the first edit to a page, we do basically the same thing, but with a subquery, because we need the one-to-many relationship between rev_page and page_id, but we only want the very first revision, which is easiest to do with a subquery (The alternative would probably be something rather complicated with group by and HAVING clauses, which gets a bit messy, especially with the other fields.) Bawolff (talk) 08:27, 18 August 2022 (UTC)
- Thanks a lot for explaining what the query do so clearly and taking the time to answer my questions.
- That's so unlucky, I am using version 1.34 and can't upgrade to the latest versions for now. 195.226.23.92 (talk) 09:16, 18 August 2022 (UTC)
- In earlier versions, you essentially just have to use rev_user_text instead of rev_actor.
- I havent tested this, because i dont have a copy of 1.34 setup, but i would guess something like
select page_namespace, page_title, (select rev_user_text from revision where rev_page = page_id order by rev_timestamp asc limit 1) 'creator', (select TIMESTAMP(rev_timestamp) from revision where rev_page = page_id order by rev_timestamp asc limit 1) 'creation date', r1.rev_user_text 'last editor', timestamp(r1.rev_timestamp) 'last edit date' from page inner join revision r1 on r1.rev_id = page_latestBawolff (talk) 10:40, 18 August 2022 (UTC)- It works!!!!
- Thank you a lot so much! THANKS!
- Have a wonderful day and keep up the good work!
- Thanks again! 195.226.23.92 (talk) 12:11, 18 August 2022 (UTC)
Errors thrown after changing PHP to version 8.1
I changed PHP version from 7.4.30 to 8.1 and got the following errors:
MediaWiki internal error.
Original exception: [d252db5c937becb1babd2770] /index.php/Main_Page TypeError: call_user_func_array(): Argument #1 ($callback) must be a valid callback, class User does not have a method "isLoggedIn" Backtrace: from /home/vvfhorg/public_html/wiki.vvfh.org/includes/StubObject.php(120)
- 0 /home/vvfhorg/public_html/wiki.vvfh.org/includes/StubObject.php(149): StubObject->_call()
- 1 /home/vvfhorg/public_html/wiki.vvfh.org/extensions/PdfBook/PdfBook.hooks.php(212): StubObject->__call()
- 2 /home/vvfhorg/public_html/wiki.vvfh.org/includes/HookContainer/HookContainer.php(338): PdfBookHooks::onSkinTemplateNavigation()
- 3 /home/vvfhorg/public_html/wiki.vvfh.org/includes/HookContainer/HookContainer.php(137): MediaWiki\HookContainer\HookContainer->callLegacyHook()
- 4 /home/vvfhorg/public_html/wiki.vvfh.org/includes/HookContainer/HookRunner.php(3485): MediaWiki\HookContainer\HookContainer->run()
- 5 /home/vvfhorg/public_html/wiki.vvfh.org/includes/skins/SkinTemplate.php(1187): MediaWiki\HookContainer\HookRunner->onSkinTemplateNavigation()
- 6 /home/vvfhorg/public_html/wiki.vvfh.org/skins/Vector/includes/SkinVector.php(424): SkinTemplate->runOnSkinTemplateNavigationHooks()
- 7 /home/vvfhorg/public_html/wiki.vvfh.org/includes/skins/SkinTemplate.php(1541): Vector\SkinVector->runOnSkinTemplateNavigationHooks()
- 8 /home/vvfhorg/public_html/wiki.vvfh.org/includes/skins/SkinTemplate.php(782): SkinTemplate->buildContentNavigationUrlsInternal()
- 9 /home/vvfhorg/public_html/wiki.vvfh.org/includes/skins/SkinTemplate.php(202): SkinTemplate->getPortletsTemplateData()
- 10 /home/vvfhorg/public_html/wiki.vvfh.org/includes/skins/SkinMustache.php(81): SkinTemplate->getTemplateData()
- 11 /home/vvfhorg/public_html/wiki.vvfh.org/skins/Vector/includes/SkinVector.php(564): SkinMustache->getTemplateData()
- 12 /home/vvfhorg/public_html/wiki.vvfh.org/includes/skins/SkinMustache.php(58): Vector\SkinVector->getTemplateData()
- 13 /home/vvfhorg/public_html/wiki.vvfh.org/skins/Vector/includes/SkinVector.php(455): SkinMustache->generateHTML()
- 14 /home/vvfhorg/public_html/wiki.vvfh.org/includes/skins/SkinTemplate.php(150): Vector\SkinVector->generateHTML()
- 15 /home/vvfhorg/public_html/wiki.vvfh.org/includes/OutputPage.php(2807): SkinTemplate->outputPage()
- 16 /home/vvfhorg/public_html/wiki.vvfh.org/includes/MediaWiki.php(926): OutputPage->output()
- 17 /home/vvfhorg/public_html/wiki.vvfh.org/includes/MediaWiki.php(939): MediaWiki::{closure}()
- 18 /home/vvfhorg/public_html/wiki.vvfh.org/includes/MediaWiki.php(563): MediaWiki->main()
- 19 /home/vvfhorg/public_html/wiki.vvfh.org/index.php(53): MediaWiki->run()
- 20 /home/vvfhorg/public_html/wiki.vvfh.org/index.php(46): wfIndexMain()
- 21 {main}
Exception caught inside exception handler: [d252db5c937becb1babd2770] /index.php/Main_Page Error: Call to undefined method User::isLoggedIn() Backtrace: from /home/vvfhorg/public_html/wiki.vvfh.org/extensions/PdfBook/PdfBook.hooks.php(212)
- 0 /home/vvfhorg/public_html/wiki.vvfh.org/includes/HookContainer/HookContainer.php(338): PdfBookHooks::onSkinTemplateNavigation()
- 1 /home/vvfhorg/public_html/wiki.vvfh.org/includes/HookContainer/HookContainer.php(137): MediaWiki\HookContainer\HookContainer->callLegacyHook()
- 2 /home/vvfhorg/public_html/wiki.vvfh.org/includes/HookContainer/HookRunner.php(3485): MediaWiki\HookContainer\HookContainer->run()
- 3 /home/vvfhorg/public_html/wiki.vvfh.org/includes/skins/SkinTemplate.php(1187): MediaWiki\HookContainer\HookRunner->onSkinTemplateNavigation()
- 4 /home/vvfhorg/public_html/wiki.vvfh.org/skins/Vector/includes/SkinVector.php(424): SkinTemplate->runOnSkinTemplateNavigationHooks()
- 5 /home/vvfhorg/public_html/wiki.vvfh.org/includes/skins/SkinTemplate.php(1541): Vector\SkinVector->runOnSkinTemplateNavigationHooks()
- 6 /home/vvfhorg/public_html/wiki.vvfh.org/includes/skins/SkinTemplate.php(782): SkinTemplate->buildContentNavigationUrlsInternal()
- 7 /home/vvfhorg/public_html/wiki.vvfh.org/includes/skins/SkinTemplate.php(202): SkinTemplate->getPortletsTemplateData()
- 8 /home/vvfhorg/public_html/wiki.vvfh.org/includes/skins/SkinMustache.php(81): SkinTemplate->getTemplateData()
- 9 /home/vvfhorg/public_html/wiki.vvfh.org/skins/Vector/includes/SkinVector.php(564): SkinMustache->getTemplateData()
- 10 /home/vvfhorg/public_html/wiki.vvfh.org/includes/skins/SkinMustache.php(58): Vector\SkinVector->getTemplateData()
- 11 /home/vvfhorg/public_html/wiki.vvfh.org/skins/Vector/includes/SkinVector.php(455): SkinMustache->generateHTML()
- 12 /home/vvfhorg/public_html/wiki.vvfh.org/includes/skins/SkinTemplate.php(150): Vector\SkinVector->generateHTML()
- 13 /home/vvfhorg/public_html/wiki.vvfh.org/includes/OutputPage.php(2807): SkinTemplate->outputPage()
- 14 /home/vvfhorg/public_html/wiki.vvfh.org/includes/exception/MWExceptionRenderer.php(157): OutputPage->output()
- 15 /home/vvfhorg/public_html/wiki.vvfh.org/includes/exception/MWExceptionRenderer.php(76): MWExceptionRenderer::reportHTML()
- 16 /home/vvfhorg/public_html/wiki.vvfh.org/includes/exception/MWExceptionHandler.php(107): MWExceptionRenderer::output()
- 17 /home/vvfhorg/public_html/wiki.vvfh.org/includes/exception/MWExceptionHandler.php(202): MWExceptionHandler::report()
- 18 /home/vvfhorg/public_html/wiki.vvfh.org/includes/MediaWiki.php(585): MWExceptionHandler::handleException()
- 19 /home/vvfhorg/public_html/wiki.vvfh.org/index.php(53): MediaWiki->run()
- 20 /home/vvfhorg/public_html/wiki.vvfh.org/index.php(46): wfIndexMain()
- 21 {main}
Do I need to revert to PHP 7.4.30? Or can this be fixed? (Yes, I know 8.0 is not yet supported.) Txantimedia (talk) 18:18, 17 August 2022 (UTC)
- BTW, reverting to PHP 8.0 still throws the error. Reverting to PHP 7.4.30, the site works fine. This is the only app preventing us from moving to PHP 8. And I should mention that we are running Mediawiki version 1.38.2 on linux 3.10.0-962.3.2.lve1.5.65.el7.x86_64. Txantimedia (talk) 18:23, 17 August 2022 (UTC)
- /home/vvfhorg/public_html/wiki.vvfh.org/extensions/PdfBook/PdfBook.hooks.php
- Sounds like the pdfbook extension is not compatible with the latest MediaWiki version. Try disabling it. —TheDJ (Not WMF) (talk • contribs) 19:48, 17 August 2022 (UTC)
- Excellent catch, @TheDJ. Disabled the extension, changed to PHP 8.1, and the wiki works. Reenabled the extension, and it fails. Disabled it again, it works. So, confirmed. The extension is the problem.
- Thank you. Txantimedia (talk) 03:46, 18 August 2022 (UTC)
- It is very unlikely this is a php 8.1 issue. User::isLoggedIn was removed from mediawiki, so its likely a mediawiki version issue. I suspect your two testing environments are using different versions of mediawiki. Bawolff (talk) 05:44, 18 August 2022 (UTC)
- No, the error was caused by the PdfBook extension, which has now been removed. Txantimedia (talk) 20:08, 8 October 2022 (UTC)
Logon takes 1 minutes when LDAPAuthentication2 is set
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 set the LDAP modules, both the local logon and the AD logon are slow. It takes about more than 1 minute to complete the logon.
(A local logon is completed pretty fast when the LDAP modules are not included in LocalSettings.php)
Do you have an idea ?
Regards
Vincent
Versioning :
- MediaWiki : 1.38.2
- PHP : 7.4.30
- MariaDB : 5.5.68
- LDAP Modules : REL1.35
LocalSettings.php (only what I added at the ond of the file) :
$ldapConfig = true;
if ( $ldapConfig) {
// Create Wiki-Group 'engineering' from default user group
$wgGroupPermissions['engineering'] = $wgGroupPermissions['user'];
// Private Wiki. External LDAP login. Default NS requires login.
$wgEmailConfirmToEdit = false;
$wgGroupPermissions['*']['edit'] = false;
$wgGroupPermissions['*']['read'] = false;
$wgGroupPermissions['*']['createaccount'] = false;
$wgGroupPermissions['sysop']['createaccount'] = false;
$wgGroupPermissions['*']['autocreateaccount'] = true;
#$wgBlockDisablesLogin = true;
wfLoadExtension( 'PluggableAuth' );
wfLoadExtension( 'LDAPAuthentication2' );
wfLoadExtension( 'LDAPAuthorization' );
wfLoadExtension( 'LDAPProvider' );
wfLoadExtension( 'LDAPGroups' );
wfLoadExtension( 'LDAPUserInfo' );
$LDAPProviderDomainConfigs = "/var/www/wiki/extensions/ldapprovider.json";
$LDAPProviderDefaultDomain = "mydomain.com";
$LDAPAuthentication2AllowLocalLogin = true;
$LDAPProviderCacheType = CACHE_NONE;
$wgPluggableAuth_EnableLocalLogin = true;
$wgPluggableAuth_ButtonLabel = "CONNEXION";
$wgPluggableAuth_EnableAutoLogin = false;
}
/var/www/wiki/extensions/ldapprovider.json :
{
"mydomain.com": {
"connection": {
"server": "myAD.mydomain.com",
"user": "CN=xxx,OU=Services,OU=Usagers,DC=mydomain,DC=com",
"pass": "xxx",
"options": {
"LDAP_OPT_DEREF": 1
},
"enctype": "clear",
"basedn": "dc=mydomain,dc=com",
"groupbasedn": "OU=Groupes,OU=Usagers,DC=mydomain,DC=com",
"userbasedn": "OU=Administrateurs,OU=Usagers,DC=mydomain,DC=com",
"searchattribute": "samaccountname",
"usernameattribute": "samaccountname",
"realnameattribute": "cn",
"emailattribute": "mail",
"grouprequest": "MediaWiki\\Extension\\LDAPProvider\\UserGroupsRequest\\UserMemberOf::factory",
"presearchusernamemodifiers": [ "spacestounderscores", "lowercase" ]
},
"userinfo": [],
"authorization": [],
"groupsync": {
"mapping": {
"engineering": "CN=xxx,OU=Groupes,OU=Usagers,DC=mydomain,DC=com",
"bureaucrat": "CN=xxx,OU=Groupes,OU=Usagers,DC=mydomain,DC=com",
"interface-admin": "CN=xxx,OU=Groupes,OU=Usagers,DC=mydomain,DC=com",
"sysop": "CN=xxx,OU=Groupes,OU=Usagers,DC=mydomain,DC=com"
}
}
}
} Vpy91 (talk) 09:44, 18 August 2022 (UTC)
- The issue had been fixed after reinstalling mariadb and reconfiguring mediawiki Vpy91 (talk) 14:14, 18 August 2022 (UTC)
Pages content not showing. but showing in history
I am using mediawiki version 1.26.0.
The problem with my site is that it is not showing the content. But when I go to history page and compare it with another version it starts to show the page content.
How can I recover content all pages from history? 2400:ADC7:106:E500:5439:EB7C:A24B:5A33 (talk) 11:18, 18 August 2022 (UTC)
- We need more info than that. Are there any errors in mediawiki debug log or php error log?
- When you compare do both the diff and rendered page contents show up or just the diff?
- In the past sometimes issues like this were caused by incompatible version of PCRE compiled into php Bawolff (talk) 21:41, 18 August 2022 (UTC)
vertical writing is possible in tables?
Is there any code to write letters vertically in
mediawiki tables? 136.228.241.58 (talk) 11:52, 18 August 2022 (UTC)
- Nothing specific but maybe you could use https://developer.mozilla.org/en-US/docs/Web/CSS/writing-mode or https://developer.mozilla.org/en-US/docs/Web/CSS/transform Bawolff (talk) 13:26, 18 August 2022 (UTC)
VisualEditor shows landigpage instead content
I've MediaWiki in Version 1.35.0. Whenever I want to edit a page with the VisualEditor, the pagecontent disapears and the startpage load in the Editor. A little bit inception like.
You can find my Wiki at https://speicher.c-p-d.info with User: Test and Passwort: Mediawiki
Maybe there is an error in the api request? https://speicher.c-p-d.info/api.php?action=visualeditor&format=json&paction=parse&page=Schulungsrichtlinien&uselang=de&formatversion=2 retuns a full html page as content... TruckerB88 (talk) 12:54, 18 August 2022 (UTC)
- @TruckerB88 Can't help with the configuration issue, but two unrelated notes: You are running an ancient, outdated, insecure version, please upgrade for your own safety. Plus the Console of the "Developer Tools" in your web browser on every page load shows an error "Error: Unknown module: jquery.tabIndex", that's also something to fix. Malyacko (talk) 17:47, 18 August 2022 (UTC)
- It would probably be an issue with the rest.php endpoint not api.php. i would guess something rewrite rules related. Bawolff (talk) 21:38, 18 August 2022 (UTC)
Display infoboxes differently on mobile
Many wikis I've seen, such as Wikipedia, have infoboxes which take up 100% of the horizontal space on mobile, and float right on desktop, taking about 30% or so of the horizontal space. I would like to replicate this, but I can't figure out how-- right now, the infoboxes get squished to the right in an unreadable fashion on mobile, as if it were just desktop with a much narrower screen.
I'm using Extension:MobileFrontend, if that helps. Celadonk (talk) 14:07, 18 August 2022 (UTC)
Transclution to interwiki with protected pages
I have a wiki setup were i was inheriting, tanscluding, templates (Lets name them Wiki B C D E) from private wiki (lets name it A) this wiki then had all the templates whitelisted.
However i was forced to update due to it being old and full of security holes and this have not broken this system. It now require me to login to access the template when transcluding. Not however when i read it as a logged out uses workes fine.
// Wiki A exsample permissions $wgGroupPermissions['*']['createaccount'] = false; $wgGroupPermissions['*']['edit'] = false; $wgGroupPermissions['*']['read'] = false; $wgWhitelistRead = [ "Template:HelloWorld" ];
Wiki B C D E then have diffrent permissions based on needs but all esessialy function the same by inheriteing the "Wiki A" templates like this:
{{raw:toA:HelloWorld}}
or
{{raw:toA:NameSomeThing |name = {{{name|}}} }}
All wikis are identical when it comes to extentsions
"Wiki A" can however transclude other public wikis but when read access required to be whitelisted the transclution seams blocked.
Are there any kind of permissions that exist to enable to allow the wiki read the Wiki A Templates? Brostrom.A (talk) 07:48, 19 August 2022 (UTC)
Version Number 1.9 not 1.09, 1.8 rather than 1.08
Manual:Database layout - MediaWiki
The table confused me because I thought the right columns were the latest as they had the biggest number ~~~~ Wakelamp (talk) 09:12, 19 August 2022 (UTC)
- Why would you count backwards? Malyacko (talk) 10:26, 19 August 2022 (UTC)
- Your response is non-productive, and I fine it insulting I wont bother in future if I see an issue. ~ Wakelamp (talk) 11:13, 19 August 2022 (UTC)
- Respectfully, nobody here is a mind reader and sometimes things need more explanation. You should not take it personally if someone asks you to explain your reasoning. We cannot address issues if we don't understand why. Bawolff (talk) 00:10, 20 August 2022 (UTC)
- Agreed I should have assumed Good Faith. I read it as a you fool statement, and I now understand it was not, .. Wakelamp (talk) 02:19, 20 August 2022 (UTC)
- I'm sorry to hear that. Let me try to rephrase: Why would 9 be bigger than 38? Malyacko (talk) 11:33, 19 August 2022 (UTC)
- Hi,
- he reason I am counting backwards, is I am used to version number tables increasing from left to right, but I always check left and right.
- So left 1.38 and the right 1.9 . Why in my case meant me I wasted time trying to work out why the category table had been deprecated>
- Why am interested in this?
- I am doing a root cause analysis on why the # of en:wiki category had increased so much. It was unlikely it was due to a schema change, but it is one oft the things I always check.
- https://en.wikipedia.org/wiki/Wikipedia:Village_pump_(idea_lab)#Files,_Templates,_and_Categories Wakelamp (talk) 02:40, 20 August 2022 (UTC)
- Category table is statistics about categories (number of pages) not the category themselves. There haven't been schema changes, but there have been bugs over the years where the counts of members were way off. I think most have been fixed at this point, but the pages in category count shouldn't be considered 100% accurate without checking. Bawolff (talk) 04:36, 20 August 2022 (UTC)
- Our version scheme is not going to change (because changing at this point would be confusing as everyone is used to the current way). It is not a decimal number. This is fairly standard in the software industry. Bawolff (talk) 00:07, 20 August 2022 (UTC)
- @Bawolff I agree versions numbers aren't decimals (although I am used to major and minor ticks eg 1.point 4 point 5
- I just thought it was just a typo. If these were the actual version numbers, then of course they must stay,, It just means that we have a 1.2 and a 1,20., I have not seen that before
- 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9
- 1.10 1.11 1.12 1.13 1.14 1.15 1.16 1.17 1.18 1.19
- 1.20 1.21 1.22 1.23 1.24 1.25 1.26 1.27 1.28 1.29
- 1.30 1.31 1.32 1.33 1.34 1.35 1.36 1.37 1.38 Wakelamp (talk) 02:40, 20 August 2022 (UTC)
- As a rule we don't make schema changes on minor versions, so the table doesn't include them (i guess to save space), but there is no 1.38, only 1.38.0, 1.38.1, and so on.
- Its all kind of irrelavent to wikipedia as wikipedia stopped using official releases since i think 1.18 and does weekly snapshots of master instead. Bawolff (talk) 04:29, 20 August 2022 (UTC)
- One last question - could you point me to the Roadmap for future releases" Wakelamp (talk) 11:29, 25 August 2022 (UTC)
- See Roadmap for what exists. There is no single roadmap for MediaWiki only. Malyacko (talk) 15:33, 25 August 2022 (UTC)
Changing filename prefix blacklist of my own mediawiki installation
Hello,
I'm running an older version of mediawiki on my NAS.
I'd like to change the blacklist of forbidden filename prefixes which can be found here:
MediaWiki:Filename-prefix-blacklist
How do I do this? Even as Administrator I can not change this page so I assume the original data is included somewhere in the PHP code ín the installation folder on the server. Could anybody please point me to it?
Thanks.
Background information: filename of uploaded image files is checked against a list of prefixes. When a match is found, a "filename-bad-prefix" message is shown to the uploader and the upload does not continue. In English version of Mediawiki this messags reads as 'The name of the file you are uploading begins with '''\"\$1\"''', which is a non-descriptive name typically assigned automatically by digital cameras. Please choose a more descriptive name for your file.' Herrmanthegerman (talk) 10:42, 19 August 2022 (UTC)
- You should be able to edit that as an admin. Some mediawiki namespace pages also require interface-admin rights but i dont think that's one of them. Bawolff (talk) 00:05, 20 August 2022 (UTC)
- Check also that on Special:listgrouprights on your wiki that your user is in a group that has editinterface rights Bawolff (talk) 00:35, 20 August 2022 (UTC)
- Thanks Bawolff.👍 Strangely enough, I can now edit this page. I don't know why I could not edit this page before.
- I checked on "Spezial:Benutzer" that my user is in the Administrator group.
- I'm not sure but I think that when I opened "MediaWiki:Filename-prefix-blacklist", there was only a "View Source" link (no "edit" link) and I clicked on it and the page had a "Save" button below the text area. 🤷♂️ Herrmanthegerman (talk) 09:23, 27 September 2022 (UTC)
Getting wikitext via js
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.
What js code should I use to store the wikitext of a page as "var wikitext" and the latest revision id of another page as "var curRevID"? Basically, I don't know how to query MW api. Thanks! —CX Zoom (A/अ/অ) (let's talk|contribs) 11:09, 19 August 2022 (UTC)
- See API:Parsing wikitext Malyacko (talk) 11:34, 19 August 2022 (UTC)
- As an example consider https://www.mediawiki.org/w/api.php?action=query&prop=revisions&titles=Main_Page&formatversion=2&rvprop=ids%7Ccontent&rvslots=main
- See also API:Revisions Bawolff (talk) 00:33, 20 August 2022 (UTC)
- Thank you! —CX Zoom (A/अ/অ) (let's talk|contribs) 04:34, 20 August 2022 (UTC)
Pop-up dialog writes output to page (using an extension)
I have a page which has a list of composers written using parsable tags such as:
<composer lastname="Beethoven", firstname="Ludwig Van" />
<composer lastname="Brahms", firstname="Johannes" />
etc
which is displayed as
Beethoven, Ludwig Van
Brahms, Johannes
etc
I have written a tag parser extension to do this. No problem here.
I would now like users to be able to add other composers to this list by clicking a button "Add Composer" - this pops up a dialog box where the users enters values for "Last Name" and "First Name". Once submitted a tag is added to the page in the format shown at the top, preferably in alphabetical order in the list.
Having read the documentation and examples, I'm stuck to even know where to start. Is this a form? I don't think so because there are multiple entries on the page.
Code like the Visual Editor which has a lot the features is just vast and getting into it is very difficult when what I need is relatively simple.
How do I start to do something like this? Is there something similar anywhere which I can base my code on?
Thanks for any help! Bigtallduck (talk) 21:05, 19 August 2022 (UTC)
- You could probably do it entirely in javascript. Create a button on the page with OOUI, make ooui dialog, get page text via api, modify page text to add new entry, save page text with api. This would be the approach most wikipedia gadgets would take and what i would reccomend (i dont have a specific example though).
- An alternative is to do something like extension MassMessage does with content handler for delivery lists. Bawolff (talk) 21:36, 19 August 2022 (UTC)
- Thanks @Bawolff yes I can see how that might work - I hadn't seen OOUI - but some of the examples seem along the right lines Bigtallduck (talk) 22:35, 19 August 2022 (UTC)
- I'll check out MassMessage as well Bigtallduck (talk) 22:36, 19 August 2022 (UTC)
- another one that might be a useful example is https://meta.wikimedia.org/wiki/Meta:FormWizard Bawolff (talk) 00:30, 20 August 2022 (UTC)
- Yes that might be a very useful shortcut Bigtallduck (talk) 08:18, 20 August 2022 (UTC)
Logo isn't visible in skin:Vector
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.
MediaWiki 1.38.2 with Skin:Vector (for desktop displays).
I have uploaded a logo image but it isn't visible.
Why is that the case?
hanekudai DOT com79.183.193.18 (talk) 15:08, 20 August 2022 (UTC)
- If I add
background-size: 190pxto the<a>tag of the logo, I can see a cropped image. - What's going on there?
- Our beloved @Bawolff 79.183.193.18 (talk) 16:05, 20 August 2022 (UTC)
- Sounds like the image is the wrong size.
- The image should be 135 px by 155 px. Even though svgs are scalable, they still need the width and height attribute set. Bawolff (talk) 16:31, 20 August 2022 (UTC)
- Can't I set the image size with CSS? 79.183.193.18 (talk) 16:35, 20 August 2022 (UTC)
- You can if you want to. It would be more normal to just make the image the right size.
- 190px is way too big though. Should be 135 px wide. Bawolff (talk) 16:42, 20 August 2022 (UTC)
- Uploaded where exactly? Set up how exactly? Please also see the "Network" tab of your web browser's Developer Tools for several other problems. Malyacko (talk) 16:14, 20 August 2022 (UTC)
- I have uploaded the image file (
source.svg) to the website directory and then added in LocalSettings.php79.183.193.18 (talk) 16:16, 20 August 2022 (UTC)$wgLogo = "$wgResourceBasePath/source.svg"; #hanekudai.png
- Hi you can go your hosting MediaWiki folder and then go to mediawiki/resources/assets/ and upload your image Prince 16:28, 20 August 2022 (UTC)
- Note, we generally dont reccomend putting it in resources/assets, because that folder will likely get overriden during upgrades. Bawolff (talk) 16:33, 20 August 2022 (UTC)
- Adding to MediaWiki:Common.css:Seems to me to solve the problem.
#p-logo a { background-size: 160px; background-position-y: 0px; background-position-x: 0; } - Feedback would be appreciated.
- @Bawolff 79.183.193.18 (talk) 16:46, 20 August 2022 (UTC)
- 0px == 0 79.183.193.18 (talk) 16:46, 20 August 2022 (UTC)
- Yes, 0 is the same regardless of unit. Bawolff (talk) 16:49, 20 August 2022 (UTC)
- Please mark thread as solved. 79.183.193.18 (talk) 19:03, 20 August 2022 (UTC)
How to get 2 lines per suggestion appearing in dynamic search results, or search against DISPLAYTITLE/strings later in title
I'm a great admirer of the second line of search results for each entry that appears dynamically as you type in the wikidata search box at https://www.wikidata.org/wiki/Wikidata:Main_Page, as it provides useful context for items that otherwise have the same names. Is this a wikibase feature, or a mediawiki extension that I could use on a non-wikibase site? My data is strongly structured, so it would be easy to set up any formatting required for the second line Vicarage (talk) 22:20, 21 August 2022 (UTC)
- I think that's a wikibase feature. Bawolff (talk) 22:35, 21 August 2022 (UTC)
- I was afraid of that. Is there a search that can provide dynamic results from matches part way through a title, or match against DISPLAYTITLE? My problem is I'm working with ships where the same names are common, and ships are often renamed, so I'm trying to set up a pattern of redirects and pages that is both unambiguous and comprehensive. Vicarage (talk) 22:49, 21 August 2022 (UTC)
- Wikibase implemented this feature replacing the default MediaWiki search:
- API request wbsearchentities implemented here;
- with this JavaScript on client side.
- Another implementation is deployed on French Wikipedia. This other implementation relies:
- on the Rest API, specifically the Search part (and if you look at the code there are even two hooks to customise the thumbnail and the description));
- on the skin Vector – I didn’t search deeply, but it’s controled by the parameter VectorWvuiSearchOptions (see Vector’s code).
- No implementation is completely out-of-the-box, some development is needed in both cases. ~ Seb35 [^_^] 07:26, 22 August 2022 (UTC)
- Probably beyond my skill level at the moment, but I will bookmark to attempt later. Thanks. Vicarage (talk) 22:55, 23 August 2022 (UTC)
how to output value of a php variable inside a table
i am trying to output a value of a php variable inside a div.
$steps = 12
$output = $this->getOutput();
$output->addHTML('<table style="border: 1px solid black;">
<tr style="border: 1px solid black;">
<th style="border: 1px solid black;"><font size=5>Week Number</font></th>
<th style="border: 1px solid black;"><font size=5>Total No. of walking</font></th>
</tr>
<tr style="border: 1px solid black;">
<td style="border: 1px solid black;"><font size=4.5><b>Week 1</b></font></td>
<td style="border: 1px solid black;"><font size=4.5>');
$output->addWikiMsg($steps);
$output->addHTML('</font></td></tr>');
my problem is the line "$output->addWikiMsg($steps);" shows output within brackets i.e, {12}. but I want to have the value without brackets.
what should I do? Misty-2409 (talk) 06:42, 22 August 2022 (UTC)
- Use addHtml not addWikiMsg. AddWikiMsg is only for adding messages. Bawolff (talk) 17:35, 22 August 2022 (UTC)
table in ifeq:
We use '{{#ifeq: "\{\{UILANGCODE}} " | "de" | Test | text } to translate the wiki side.
If we try to use a table in the text-section only a { is displayed. To mask | with {{|}} is not successful. How do we convince the parser? DMBrosig (talk) 09:13, 22 August 2022 (UTC)
- Maybe use HTML. Maybe use a template.
- Are you missing a closing }? Jonathan3 (talk) 19:38, 22 August 2022 (UTC)
- This is one solution, but maybe we find a way in wiki code... DMBrosig (talk) 06:57, 24 August 2022 (UTC)
- Can you include exactly the wikitext being used Bawolff (talk) 03:44, 23 August 2022 (UTC)
- DMBrosig (talk) 06:36, 24 August 2022 (UTC)
{{#ifeq: "{{UILANGCODE}}" | "de" | === angebotene Dienste ==== Tabelle folgt... {| style="text-align: left" border="1" cellpadding="1" cellspacing="1" |- ! Name || interner Link || Kurzbeschreibung || Datenschutzhinweise |- | ... || ... || ... || ... |} | ==== Services offered ==== List follows... {| style="text-align: left" border="1" cellpadding="1" cellspacing="1" |- ! Name || internal link || description || data protection information |- | ... || ... || ... || ... |} }} - Ah, i see.
- You can't use wiki-table syntax inside parser functions.
- Normally what people do, is the make each version of the table a separate template, which they can translcude.
- Other options include using html table syntax (<table> etc), or translating everything on a cell by cell level, instead of the entire table at once. Bawolff (talk) 08:21, 24 August 2022 (UTC)
- HTML table works... DMBrosig (talk) 14:01, 24 August 2022 (UTC)
ExternalData error with MSSQL
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, few days ago I configured ExternalData extension and since then I'm constantly trying to connect to database. I have odbc and driver successfully installed. The error emerges after connecting to database when I try to write a clauses.
Type error from line 169 .../EDConnector.php: Argument 2 passed to EDConectorOdbc::from() must be of the type array, null given ...
Can anyone point me right direction to resolve this problem? ChrisOlx (talk) 09:57, 22 August 2022 (UTC)
- @ChrisOlx Hi, please see "Post a new question" in the side bar and provide both MediaWiki version and extension git revision/branch - thanks. Malyacko (talk) 12:30, 22 August 2022 (UTC)
- The extension author would likely reply if you ask on its talk page, I'm sure. Jonathan3 (talk) 19:36, 22 August 2022 (UTC)
JavaScript code runs from console but not from Common.js
window.setTimeout(()=>{
document.body.insertAdjacentHTML('beforeend', `
<aside class="cbwtphone_wrapper">
<a class="cbwtphone_link" href="tel:NUMBER">
<span class="cbwtphone_text">התקשרו עכשיו</span>
<img class="cbwtphone_icon" src="https://upload.wikimedia.org/wikipedia/commons/d/d4/Phone_communication_icon.png"></img>
</a>
</aside>
`)
}, 1000);
79.183.193.18 (talk) 11:25, 22 August 2022 (UTC)
- MediaWiki 1.38.2 79.183.193.18 (talk) 11:41, 22 August 2022 (UTC)
- @Krinkle 79.183.193.18 (talk) 11:51, 22 August 2022 (UTC)
- Please do not ping random people. Thanks. Malyacko (talk) 12:20, 22 August 2022 (UTC)
- It's not a random person, it's a person who helped in a similar thread:
- Project:Support desk/Flow/2019/07#h-JavaScript_works_in_Chrome_console_but_not_in_Common.js-2019-07-03T00:54:00.000Z 79.183.193.18 (talk) 12:22, 22 August 2022 (UTC)
- Probably should use a DOMContentLoaded event ($) rather than window.setTimeout Bawolff (talk) 03:43, 23 August 2022 (UTC)
- @Bawolff This didn't work2A10:8012:9:24AC:747C:8C45:AD2:8219 (talk) 15:08, 24 August 2022 (UTC)
window.addEventListener('DOMContentLoaded', () => { SAME_CODE_AS_ABOVE });- There can be lots of causes for it not to work. Check for js errors in console. Bawolff (talk) 19:28, 30 August 2022 (UTC)
- Community? 2A10:8012:D:5415:C96A:416E:F4FC:FEE (talk) 11:24, 26 August 2022 (UTC)
- Community! Malyacko (talk) 11:32, 26 August 2022 (UTC)
- https://m.youtube.com/watch?v=KsyzP8pkaTI Bawolff (talk) 19:27, 30 August 2022 (UTC)
- Does ES6 syntax works on Common.js? I see there are no arrow functions on en.wp Common.js. ~ Seb35 [^_^] 06:21, 4 September 2022 (UTC)
Cannot access, move, or delete articles whose name begins with a space
I am the administrator of slymods.info, a wiki hosted on Miraheze (v1.38.2 / 29f90ba), and I've encountered a nasty bug that our stewards are having trouble solving. I inadvertently created articles that start with a space _ character and I cannot access, move, edit, or delete them.
The way I achieved this was by creating an article along the lines of Foo:_Bar, then creating a namespace called Foo. The end result is an article named _Bar in the Foo namespace that cannot be accessed in any way as it forces you to Foo:Bar which doesn't exist. Deleting the namespace doesn't work as it just moves it back to mainspace as _Bar.
There is no error message and I can't find any documentation of this bug or any instances of someone else having this issue. Google has been no help because it just turns up man pages about using whitespace in wikitext.
Has anyone had this issue before, or know how to solve it? In this particular case I would be fine with deleting the articles as they are stubs with basically no content. I'm not sure how much information you can glean from the wiki itself, but in case it helps, the actual offending articles are here:
Sly 2:_Band_Of_Thieves_Honor_Among_Thieves_Honour_Among_ThievesTheOnlyZac (talk) 01:46, 23 August 2022 (UTC)
- You can still access via page id in the api.
- Usually you can manually move via api using page id (227).
- The reccomended way is to run namespaceDupes.php Bawolff (talk) 03:37, 23 August 2022 (UTC)
How to connect php and mysql database?
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.
How to connect php and mysql database? Vishnudk0906 (talk) 09:01, 23 August 2022 (UTC)
- mysqli library can be used to connect php with mysql database by specifying sql server,user name,password and database name. Vishnudk0906 (talk) 09:02, 23 August 2022 (UTC)
HOW TO CONNECT MYSQL SERVER?
connectivity issues Vishwanathpro (talk) 09:27, 23 August 2022 (UTC)
- @Vishwanathpro Please read both "Before you post" and "Post a new question" in the sidebar. Thanks! Malyacko (talk) 12:47, 23 August 2022 (UTC)
Orphaned pages: How to update which pages are shown in Special:LonelyPages?
In my wiki, I currently see 214 pages listed in Special:LonelyPages (which is titled "Orphaned pages").
But almost all of these 214 pages are linked from or transcluded into other pages in my wiki.
Is there any way to update which pages are shown here? Ulf Dunkel (talk) 11:07, 23 August 2022 (UTC)
- So if $wgMiserMode is false (default) this should be updated instantly (and in which case you are probably mistaken about thepage not meeting criteria). If it is true, you need to run updateSpecialPages.php Bawolff (talk) 16:00, 23 August 2022 (UTC)
- @Bawolff: Thank you for your recommendation, although it didn't solve my issue. In my CommonSettings.php (for all my interwiki instances) and all my LocalSettings.php files, $wgMiserMode wasn't defined explicitely, so it will be false (default).
- I even added it as
$wgMiserMode = false;to my CommonSettings.php and ran /maintenance/updateSpecialPages.php. That script listed "Lonelypages [QueryPage] got 214 rows in 0.04s" (beside others). The special page hasn't changed its content. - Any other idea? Ulf Dunkel (talk) 11:47, 24 August 2022 (UTC)
- Most likely they meet mediawiki's definition of a lonelypage, which might differ from what intuitively you think it is. Bawolff (talk) 16:50, 24 August 2022 (UTC)
- The definition of a lonelypage seems to be consistent in all MediaWiki instances: "The following pages are not linked from or transcluded into other pages in MediaWiki." I checked the orphaned pages listed on my wiki to and fro - they all are linked from or transcluded into other pages in my wiki.
- Any other idea? Ulf Dunkel (talk) 15:49, 1 September 2022 (UTC)
- its possible links table is inconsistent. You could run refreshLinks.php (might be slow) Bawolff (talk) 22:30, 8 September 2022 (UTC)
- I ran refreshLinks.php now and received errors for almost each of the checked links, like this:
PHP Notice: Trying to access array offset on value of type null in /var/www/vhosts/intactiwiki.org/w/en/includes/profiler/SectionProfiler.php on line 100PHP Notice: Trying to access array offset on value of type null in /var/www/vhosts/intactiwiki.org/w/en/includes/profiler/SectionProfiler.php on line 99PHP Notice: Trying to access array offset on value of type null in /var/www/vhosts/intactiwiki.org/w/en/includes/profiler/SectionProfiler.php on line 101- My wiki version is 1.32.2. Should I try an upgrade to a more recent version of the wiki first of all? Ulf Dunkel (talk) 07:42, 26 September 2022 (UTC)
- I fixed the SectionProfiler.php by changing lines 99-101 into
if ( (!$this->start) && (!$this->end) ){$totalCpu = $totalReal = $totalMem = 0;}else{$totalCpu = max( $this->end['cpu'] - $this->start['cpu'], 0 );$totalReal = max( $this->end['real'] - $this->start['real'], 0 );$totalMem = max( $this->end['memory'] - $this->start['memory'], 0 );}- The script then ran through without any error, but also without fixing any illegal entries from the links table. Ulf Dunkel (talk) 08:37, 26 September 2022 (UTC)
Can't load my svg file
Hi all! I have been making the map for 4 months, and now I have completed it and started uploading it here. I waited 5 minutes, and then Dikwarehouse writes that "This file did not pass the verification procedure." At the beginning of the download, he gave me that this file was already downloading. Tried again - same result. Resaved my file as "plain SVG", tried again - same result. What to do? Tell me please.
P.S.: I want to upload this file in svg format in any case, so that everything is beautiful. The file weight is 239 MB, if that matters.
P.P.S.:I exported this SVG file to a PNG file via Inkscape. I got a PNG file weighing 343 MB. I started uploading this file to Wikimedia Commons. And I managed to download it! Further buttons open in the Download Wizard. So it's not about the file size! And in what? I don't know..
P.P.P.S:I tried uploading my SVG file via Chunked upload but no result..."00339: FAILED: stashfailed: This file did not pass file verification." What is a file check? Why is my file not passing it?~ Пётр Тарасьев (talk) 15:03, 23 August 2022 (UTC)
- Usually this means the file was recognized as some sort of other format, or it failed a security check (e.g. the file had javascript in it) Bawolff (talk) 15:58, 23 August 2022 (UTC)
- @Bawolff, Is there a way to remove Javascript?~~~~ Пётр Тарасьев (talk) 16:23, 23 August 2022 (UTC)
- if its a choice importImages.php is easier (if this is for wikimedia commons, you might be able to request that on phabricator). Chunked upload might also require all chunks to be valid svg files, i am not sure. Bawolff (talk) 04:28, 24 August 2022 (UTC)
- thanks for the answer) Пётр Тарасьев (talk) 07:03, 24 August 2022 (UTC)
Hide Preferences Tabs
I am using MW 1.35.6 and would like to hide the "Search" and "Notifications" tabs in all users' preferences. I understand "Notifications" is added from the extension, so I may need to modify the code to remove this?
I've tried modifying "$wgDefaultUserOptions" and "Common.css" but still can't get them to hide. Molsen7970 (talk) 19:47, 23 August 2022 (UTC)
- default user options and $wgHiddenPrefs wouldnt affect the tabs.
- if using mediawiki:common.css be sure to set $wgAllowSiteCSSOnRestrictedPages to true.
- It might be possible with Manual:Hooks/GetPreferences but i still would generally just reccomend the css approach instead Bawolff (talk) 23:30, 23 August 2022 (UTC)
One Mediawiki with several domains
How to turn on this feature? I have several domains to park them to host. But the all redirect to main domain in LS file. Please help. PrometheusAla (talk) 20:35, 23 August 2022 (UTC)
- Make sure $wgServer is set appropriately. See also manual:Wiki farm Bawolff (talk) 23:26, 23 August 2022 (UTC)
- I read it but didn't undestand which case is for my situation? 2 different domain names for one MW with common DB? PrometheusAla (talk) 19:21, 24 August 2022 (UTC)
- Can you be more specific as to the behaviour you want? Do the domains redirect? Are they not redirects but show the same wiki? Something else? Bawolff (talk) 09:07, 25 August 2022 (UTC)
- I have two domain names. I want to make them to open the same Wikimedia with desired URL in browser line. Without any redirects PrometheusAla (talk) 10:53, 25 August 2022 (UTC)
- You would have to have $wgServer dynamically set.
- Some people also set $wgRenderHashAppend to different things depending on url. Bawolff (talk) 03:02, 26 August 2022 (UTC)
- How to do it? I'm not a programmer, sorry PrometheusAla (talk) 07:16, 3 September 2022 (UTC)
- Please? PrometheusAla (talk) 17:53, 5 September 2022 (UTC)
PDFs not opening correctly, pages shows scrambled code
We recently updated our MediaWiki page with the newest version (https://hovpedia.hov.org/). Now when we upload PDFs, we get a scrambled page of code, see screenshot: https://hov.org/media/2851/screenshot-hovpedia.png All our old PDFs are also opening up with scrambled code. HELP!! Thanks, Michelle Msaldanachiago (talk) 15:27, 24 August 2022 (UTC)
- So this is a mime type error.
- Can you check if you have any errors in your php error log? Look especially for "headers already sent" errors. Bawolff (talk) 16:52, 24 August 2022 (UTC)
- Please help. How do I pull the php error log? Msaldanachiago (talk) 21:57, 26 August 2022 (UTC)
- How to debug has info Bawolff (talk) 21:09, 28 August 2022 (UTC)
- Oh OK. I'll check the error log. Thanks. Msaldanachiago (talk) 17:14, 24 August 2022 (UTC)
MediaWiki 1.35.6 Moment.js Upgrade
We are being flagged to a high security vulnerability in MW 1.35.6 for an out-of-date Moment.js version. Is there a way to upgrade Moment.js in MW? Molsen7970 (talk) 18:58, 24 August 2022 (UTC)
- The Moment issue fixed in 2.29.2 only "impacts npm (server) users of moment.js" Malyacko (talk) 08:23, 25 August 2022 (UTC)
- Does the out of the box mediawiki in v1.35.6 involve any access to WIki api through npm?
- Also, what will be the evidence to submit to security folks that this vulnerability is a false positive or not an impact with the out of the box install? Armfns001 (talk) 02:05, 26 August 2022 (UTC)
- No, we dont use npm for anything other than unit tests. Bawolff (talk) 02:59, 26 August 2022 (UTC)
How can I make my Wikipedia
- Can u please tell me how can I make my Wikipedia 2405:201:5504:E048:30D0:CA84:B880:5405 (talk) 19:05, 24 August 2022 (UTC)
- If you want to make a MediaWiki website, check Manual:Installing MediaWiki.
- If you want it to look like Wikipedia, or to have the same possibilities, you might want to check Wikipedia's "Special:Version" page, where its skins, extensions and libraries are listed. LMamo (talk) 12:25, 14 September 2022 (UTC)
- Wikipedia already exists. If you want to install the MediaWiki software yourself on your own server, see https://www.mediawiki.org/ Malyacko (talk) 08:06, 25 August 2022 (UTC)
How to completely clean Flow?
How to completely clean Flow from Mediawiki and reinstall it? Not working correctly after upgrade! https://бахаи.kz PrometheusAla (talk) 19:20, 24 August 2022 (UTC)
- Have you tried to update the extensions after MW upgrade? Fokebox (talk) 08:35, 25 August 2022 (UTC)
- Yes, of course. And now it has the same error. All the messages are corrupt and doesn't work. I can't do anything with this and nobody can advice anything about my case. PrometheusAla (talk) 10:55, 25 August 2022 (UTC)
How to reduce the width of 2 columns via CSS
Does anyone know how to reduce the width only of the 2 grey boxes by 20% via CSS?
http://www.futureofmankind.co.uk/Billy_Meier/Test Fomkwiki (talk) 22:05, 24 August 2022 (UTC)
Preload functionality not working
I am on the latest mediawiki. I am trying to get the preload functionality to work on my site.
I have followed the instructions at Manual:Creating pages with preloaded text
I have created a template at: http://fivebarsrest.org/mediawiki/wiki/Template:Work
I have created the preload file at http://fivebarsrest.org/mediawiki/wiki/Template:Work/Preload
So If I enter enter the URL http://fivebarsrest.org/mediawiki/wiki/Symphony_No_1?action=edit§ion=new&preload=Template:Work/Preload that should load a page called "Symphony No 1" with the preloaded text? Instead I just get the message: "There is currently no text in this page. You can search for this page title..."
What am I doing wrong? Does something special have to be installed on the server? It is standard functionality I thought.
Thanks for any help Bigtallduck (talk) 23:10, 24 August 2022 (UTC)
- You need a url like http://fivebarsrest.org/mediawiki/index.php?title=Symphony_No_1&action=edit§ion=new&preload=Template:Work/Preload Bawolff (talk) 02:14, 25 August 2022 (UTC)
- That's great thanks! Bigtallduck (talk) 07:43, 25 August 2022 (UTC)
Update of MediaWiki Extensions
I don't know how to update the MediaWiki extension, could you please tell me? ナムコォッ! (talk) 00:41, 25 August 2022 (UTC)
- Manual:Upgrading#Upgrade_extensions Malyacko (talk) 04:59, 25 August 2022 (UTC)
- I understand how to use MwExtUpgrader, but in which file should I write
php mwExtUpgrader.phar? ナムコォッ! (talk) 11:19, 25 August 2022 (UTC) - On the command line, wherever that third-party extension "MwExtUpgrader" installs its code, if you plan to use that third-party extension. Malyacko (talk) 15:34, 25 August 2022 (UTC)
MW 1.38.2: Trouble installing Wikibase
I've followed all the instructions, installed Composer, etc. I've tried altering the composer.local.json file many times, but to absolutely no avail. Each time I load the Wikibase extension into LocalSettings, I'm greeted on my wiki with this:
Exception caught inside exception handler: [fa6ff3e9b39b8f96cbeb2d12] /mediawiki/index.php/Main_Page Error: Class "DBAccessBase" not found
Backtrace:
from C:\xampp\htdocs\mediawiki\extensions\Wikibase\lib\includes\Store\Sql\WikiPageEntityMetaDataLookup.php(28)
#0 C:\xampp\htdocs\mediawiki\includes\AutoLoader.php(116): require()
#1 C:\xampp\htdocs\mediawiki\extensions\Wikibase\data-access\src\SingleEntitySourceServices.php(282): AutoLoader::autoload(string)
#2 C:\xampp\htdocs\mediawiki\extensions\Wikibase\data-access\src\SingleEntitySourceServices.php(223): Wikibase\DataAccess\SingleEntitySourceServices->getEntityMetaDataAccessor()
#3 C:\xampp\htdocs\mediawiki\extensions\Wikibase\data-access\src\MultipleEntitySourceServices.php(67): Wikibase\DataAccess\SingleEntitySourceServices->getEntityRevisionLookup()
etc., etc. (it goes on for a while)
I've been scouring the internet for days but I barely find any results and the few forums I do find are from decades ago and mostly unhelpful. I would really appreciate any help as without this extension I can't use infoboxes on my wiki, which is a fairly important aspect. Please, I would be so grateful. Thanks in advance. 2A00:23C7:4410:6F01:E9F2:CA08:2230:21C5 (talk) 23:49, 25 August 2022 (UTC)
- It sounds like you might be using an old version of Wikibase, with a 1.38 or later version of MediaWiki core. The DBAccessBase class was removed from core in 1.38. It's not loaded via Composer so that shouldn't be an issue. Sam Wilson 01:20, 26 August 2022 (UTC)
- I was using 1.36 version of Wikibase, which appears to be the latest. 2A00:23C7:4410:6F01:E9F2:CA08:2230:21C5 (talk) 01:24, 26 August 2022 (UTC)
Significant lag when handling templates
I'm mostly referring to templates imported from Wikipedia. I can't even access the Infobox template page because it caps out at two minutes loading time. This might have something to do with me using 'commons' as the interwiki prefix every time I imported templates. Could anyone help me out? Thanks 2A00:23C7:4410:6F01:ADF4:8B17:F0DE:128C (talk) 04:17, 26 August 2022 (UTC)
- Could be a lot of things. You could try Profiling.
- What is $wgMainCacheType set to? Bawolff (talk) 04:22, 26 August 2022 (UTC)
- $wgMainCacheType is set to CACHE_NONE, if that helps 2A00:23C7:4410:6F01:54F0:9D06:ACB1:9E04 (talk) 11:20, 26 August 2022 (UTC)
- Ok, I installed APCu and set $wgMainCacheType to CACHE_ACCEL, but it's still hideously slow. Maybe it's an issue with XAMPP or Apache? There are so many possible roots to this problem and I don't know if I can fix it. 2A00:23C7:4410:6F01:54F0:9D06:ACB1:9E04 (talk) 12:40, 26 August 2022 (UTC)
- Update: I have tried to install both APCu and Memcached but information is scant and I haven't been able to get either of them working. Is this the part of the problem? Community? 2A00:23C7:4410:6F01:54F0:9D06:ACB1:9E04 (talk) 13:14, 26 August 2022 (UTC)
- apcu and memcached are about the same in a single server setup. I'd reccomend concentrating on apcu as it is easier. Bawolff (talk) 19:40, 26 August 2022 (UTC)
- Community!
- Have you checked Manual:Performance tuning? Malyacko (talk) 18:02, 26 August 2022 (UTC)
- Yes I have. I've tried pretty much everything so I'm pretty sure it's to do with the cache. I just couldn't figure out how to install either APCu or Memcached though. 2A00:23C7:4410:6F01:54F0:9D06:ACB1:9E04 (talk) 19:24, 26 August 2022 (UTC)
- Yes I have. I've tried pretty much everything so I'm pretty sure it's to do with the cache. I just couldn't figure out how to install either APCu or Memcached though. 2A00:23C7:4410:6F01:54F0:9D06:ACB1:9E04 (talk) 19:24, 26 August 2022 (UTC)
- What have you tried and where did you get stuck installing apcu? Bawolff (talk) 19:41, 26 August 2022 (UTC)
- I just don't know where to install the correct version from. I found a few but none worked. There was something about putting a .dll file into php/ext but that didn't work, either. 2A00:23C7:4410:6F01:54F0:9D06:ACB1:9E04 (talk) 20:39, 26 August 2022 (UTC)
- I just don't know where to install the correct version from. I found a few but none worked. There was something about putting a .dll file into php/ext but that didn't work, either. 2A00:23C7:4410:6F01:54F0:9D06:ACB1:9E04 (talk) 19:57, 26 August 2022 (UTC)
- https://www.php.net/book.apcu links to https://www.php.net/manual/en/apcu.installation.php and https://www.php.net/manual/en/install.pecl.windows.php Malyacko (talk) 03:41, 27 August 2022 (UTC)
- Ok, I followed all the steps and compiled the APCu source. It tells me to look inside the Release_TS file for the compiled extension but in the pecl\apcu-master directory there are only .obj and .sbr files; no .dll files or anything. How do I transfer the APCu extension to my XAMPP php? 2A00:23C7:4410:6F01:A118:8CE9:5C88:6F3E (talk) 15:04, 27 August 2022 (UTC)
- You compiled apcu from source? Bawolff (talk) 03:37, 28 August 2022 (UTC)
- Also, I ran 'php -m' in the command prompt but APCu didn't show up, meaning it isn't loaded properly. 2A00:23C7:4410:6F01:A118:8CE9:5C88:6F3E (talk) 15:09, 27 August 2022 (UTC)
- Ok, I followed all the steps and compiled the APCu source. It tells me to look inside the Release_TS file for the compiled extension but in the pecl\apcu-master directory there are only .obj and .sbr files; no .dll files or anything. How do I transfer the APCu extension to my XAMPP php? 2A00:23C7:4410:6F01:A118:8CE9:5C88:6F3E (talk) 15:04, 27 August 2022 (UTC)
- If you follow some docs, please link to those docs. Otherwise we all guess. Thanks. Malyacko (talk) 03:41, 27 August 2022 (UTC)
- Ok, ignore everything above. I managed to install the .dll and it's enabled in the phpinfo.php page. However, the templates are still aggravatingly slow. Installing APCu didn't help at all. What do I do now? 2A00:23C7:4410:6F01:A118:8CE9:5C88:6F3E (talk) 15:26, 27 August 2022 (UTC)
- What is apcu.shm_size set to in php.ini? Also did you set $wgMainCacheType = CACHE_ACCEL; ?
- Lack of Object caching is just one of many potential things that can cause slowness. Bawolff (talk) 03:44, 28 August 2022 (UTC)
- Yes, I changed it to CACHE_ACCEL. My apc.shm_size is set to 32M. Sorry for the late reply, I've been rather busy. 2A00:23C7:4410:6F01:ADD5:F3C1:2ADB:7BC (talk) 23:30, 29 August 2022 (UTC)
- I would generally reccomend an shm_size of 64M, but 32M is probably ok.
- You could try using Profiling to try and figurexwhat part is slow. Bawolff (talk) 01:23, 30 August 2022 (UTC)
- This article is written with Linux and such in mind. I am using Windows 2A00:23C7:4410:6F01:ADD5:F3C1:2ADB:7BC (talk) 02:23, 30 August 2022 (UTC)
JavaScript code inside DOMContentLoaded or load don't work
1.38.2.
MediaWiki:Common.js codes such as the following (with DOMContentLoaded or load events) don't work.
The codes work in browser console, but not in Common.js.
window.addEventListener('DOMContentLoaded', ()=>{
alert("Hi");
});
Why? 2A10:8012:D:5415:B197:F60D:BC7:B498 (talk) 13:33, 26 August 2022 (UTC)
- The alert itself works in browser console, not the entire code because the aforementioned events already happened. 2A10:8012:D:5415:B197:F60D:BC7:B498 (talk) 13:40, 26 August 2022 (UTC)
- Is this different from Project:Support desk/Flow/2022/08#h-JavaScript_code_runs_from_console_but_not_from_Common.js-20220822112500 ? Malyacko (talk) 17:56, 26 August 2022 (UTC)
- Yes, it's focused on the two events in hand. 2A10:8012:D:5415:280A:1214:C081:C2AE (talk) 18:19, 26 August 2022 (UTC)
CollapsibleSections Extension breaks MW 1.38
How can I get CollapsibleSections (or HideSection) extension to work with MediaWiki 1.38?
I can install and activate CollapsibleSections extension, but when I add $wgCollapsibleSectionsCollapsedByDefault to LocalSettings, the site breaks and nothing displays in browser.
I want to collapse H2 headers; is that possible with CollapsibleSections extension?
Alternately, HideSection extension works fine but does not collapse headers by default. Is there a way to do that?
Also, HS produces error which doesn't seem to interfere with functionality, but requires disabling ShowExceptionDetail and DevelopmentWarnings in LocalSettings.
Is there a way to fix HideSection error and collapse headers by default?
HS error -
Deprecated: Use of ParserSectionCreate hook (used in HideSectionHooks::onParserSectionCreate) was deprecated in MediaWiki 1.35. [Called from MediaWiki\HookContainer\HookContainer::run in /home/.../domains/....com/public_html/MOD/includes/HookContainer/HookContainer.php at line 137] in /home/.../domains/....com/public_html/MOD/includes/debug/MWDebug.php on line 377 DStallTX (talk) 22:11, 26 August 2022 (UTC)
- That's not an error. That's a warning only. Malyacko (talk) 03:39, 27 August 2022 (UTC)
- How can I set HideSection extension to collapse by default?
- How can I hide warning without disabling ShowExceptionDetail and DevelopmentWarnings in LocalSettings? DStallTX (talk) 13:12, 27 August 2022 (UTC)
- From a quick look, you'd likely be better with the newer extension.
- Sounds like you just messed up your LocalSettings.php - what exactly did you add?
- Not sure the setting is what you want though. The description on the extension page isn't clear to me without experimenting.
- Most people keep those two debugging variables false. Jonathan3 (talk) 23:50, 28 August 2022 (UTC)
ADMINISRATIVE CODE
Howdy I find my administrative code for my Wikipedia page? JOSEPH CARRARO 96.92.66.249 (talk) 00:06, 27 August 2022 (UTC)
- No idea what you are talking about Bawolff (talk) 01:46, 27 August 2022 (UTC)
(SOLVED: DON'T BOTHER REPLYING) Links not turning blue after page creation
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 usually create page links before I create the pages themselves. When I create the page, the corresponding links turn a brown/red colour and display 'page does not exist' when hovered over. Clicking on the link takes me to the page, however. The only way I have found to alleviate this issue is to edit the page, remove the links, then edit the links back in, but this can be frustrating, especially when there are infobox templates involved. Anyone know how to fix this? 2A00:23C7:4410:6F01:A118:8CE9:5C88:6F3E (talk) 17:42, 27 August 2022 (UTC)
remove/delete mediawiki account
I want to delete my mediawiki account. I don't know how to do that. I am not good at such a thing. Help needed. gordi (talk) 22:05, 27 August 2022 (UTC)
Categories not displaying compontnet count.
- Hi all.
- Im using MediaWiki 1.34.2.
- I am trying to get more diligent about categorizing my data and pages to keep everything sorted.
- On the other Wikis I have seen there is a count indicator of how many items belong to a category. For example:
- >Example Category (2C, 34P, 51F)
- While I can use the
- tag to make files be part of that category, my wiki isnt showing the subordinate component count. Im not really sure what the "correct" term is for that, so Im not having much luck finding a tutorial on how to make it work.
- You can see an example of a category with sub,categories sans counts here:
- https://claybornglobal.com/IHF/index.php/Category:Invader_Bases
- Any help would be appreciated. Thanks! 2600:8800:5021:B700:40E0:7D22:77F6:22E1 (talk) 22:19, 27 August 2022 (UTC)
- 1.34.2 is an outdated, ancient, unsupported, insecure MediaWiki version. Please upgrade for your own safety. Malyacko (talk) 01:06, 28 August 2022 (UTC)
- Thanks for that. I did update to 1.38.2. 2600:8800:5021:B700:40E0:7D22:77F6:22E1 (talk) 17:56, 28 August 2022 (UTC)
- Its part of extension:CategoryTree Bawolff (talk) 00:36, 28 August 2022 (UTC)
- That fixed it, thank you! 2600:8800:5021:B700:5DA4:C36D:133:CE19 (talk) 19:38, 28 August 2022 (UTC)
Retrieving images created with templates via api
Hello
I have created images within pages using the cover logo template. I want to retrieve the image via api (or any other ways) so that I can display in another page.
Any ideas?
Thank you
halj Halojit (talk) 01:08, 28 August 2022 (UTC)
- @Halojit Hi, please see and follow "Post a new question" in the sidebar and provide all required info. Also, what is "the cover logo template"? Where would "another page" be located? Thanks. Malyacko (talk) 13:28, 28 August 2022 (UTC)
- Find the image's URL and use that? Maybe look at Special:NewFiles. Jonathan3 (talk) 23:39, 28 August 2022 (UTC)
access database table from main 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.
I have a username table where I have two types of user. I want to give user of a specific group say 'group 1' to a link from the main page. I am trying to read the user's group number from the username table by using their username. and if it is group 1 I will show the link, otherwise not. I don't know how to access select query from main page Misty-2409 (talk) 21:45, 28 August 2022 (UTC)
- Where is the table? Jonathan3 (talk) 23:36, 28 August 2022 (UTC)
- in the mysql database. i have linked mediawiki with mysql database using xampp Misty-2409 (talk) 21:15, 29 August 2022 (UTC)
- Maybe you could create a database on the wiki using Extension:Cargo and add Cargo queries to the main page.
- Or you could maybe query your existing database using Extension:External Data.
- If it's not a big database table you could maybe just put the logic in a template instead, maybe using Help:Extension:ParserFunctions##switch. Jonathan3 (talk) 22:07, 29 August 2022 (UTC)
- Extension:External Data and Extension:ParserFunctions##switch solved my issue.
- Thank you so much for your support Misty-2409 (talk) 18:53, 30 August 2022 (UTC)
- You're welcome! :-) Jonathan3 (talk) 20:44, 31 August 2022 (UTC)
Navboxes not working
Hi everyone. I'm using 1.38.2.
I am trying to get the Navboxes to work on my site.
I have looked at the examples given here:
Template:Wikipedia essays - Wikipedia
and here: Template:Navbox with collapsible groups - Wikipedia
However, whenever I created my file and save it, I get a red link that says "Template:Navbox with collapsable groups does not exist on this wiki". Do I have to enable this feature somehow? Is it an extension?
Any help would be appreciated, thank you. 2600:8800:5021:B700:5DA4:C36D:133:CE19 (talk) 23:51, 28 August 2022 (UTC)
Help needed!!
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.
Is anybody a Wikipedia superuser/checkuser or administrator with the permission to review a deleted page?
If so it would be nice to hear from you.
Peace! AlgorithmGG (talk) 02:21, 29 August 2022 (UTC)
- Please ask at Wikipedia. This isn’t the right place to ask. Tropicalkitty (talk) 02:26, 29 August 2022 (UTC)
- Nice one Tropicalkitty i was being sociable before I went there! Hope you're good. AlgorithmGG (talk) 02:33, 29 August 2022 (UTC)
Overwrite permissions in an extension?
MW 1.35
I have an extension that I want to modify existing permissions for. This used to work in 1.27 but with the upgrade, I can't seem to get it working.
I tried both methods, putting it in an extension.json *and* calling it as a hook:
extension.json example:
"GroupPermissions": { "*": { "createaccount": false, "edit": false, "read": false }, "user": { "edit": false, "createtalk": false, ....}
Hook example:
"Hooks": { "BeforeInitialize": "CustomWikiGroups::onBeforeInitialize" },
public static function onBeforeInitialize() { $wgGroupPermissions['user']['edit'] = false; } } Rijvirajib (talk) 13:48, 29 August 2022 (UTC)
- I would normally use the "callback" feature of extension.json for sonething like that https://www.mediawiki.org/wiki/Manual:Extension.json/Schema#callback
- Your hook isnt working because you are missing a global decleration. Bawolff (talk) 23:43, 29 August 2022 (UTC)
How to fix short titles?
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 my wiki https://joinfediverse.wiki/ we use short titles like https://joinfediverse.wiki/Main_Page but since I had to restore from a backup they are broken. The main page can be found under https://joinfediverse.wiki/index.php?title=Main_Page but none of the links work.
I found this: https://shorturls.redwerks.org/?url=https%3A%2F%2Fjoinfediverse.wiki%2FMain_Page but still couldn't get it to work.
Where do I find the correct fastcgi_pass and fastcgi_params? PKFP (talk) 16:34, 29 August 2022 (UTC)
- How were you making short URLs before? Have you replicated that in the restored version? Jonathan3 (talk) 10:25, 30 August 2022 (UTC)
- Someone else always did it for me, but I can't get a hold of him. PKFP (talk) 13:16, 30 August 2022 (UTC)
- Is the restored version on the same server as the broken version? Jonathan3 (talk) 18:06, 30 August 2022 (UTC)
- No it's a different server. But if I restore it on the same server it's the same issue. PKFP (talk) 07:52, 31 August 2022 (UTC)
- Does Manual:Short URL/Nginx help? Bawolff (talk) 00:52, 1 September 2022 (UTC)
- That's what lead me to the link above. Other than that it didn't help PKFP (talk) 10:28, 1 September 2022 (UTC)
- I just found this in my LocalSettings.php:
- ##Hack to stop YNH updates from overwriting Short URL config
- require_once 'Custom.php';
- So I copied Custom.php.save to Custom.php, but it's still the same issue PKFP (talk) 09:37, 2 September 2022 (UTC)
- Any ideas? PKFP (talk) 15:08, 4 September 2022 (UTC)
- What's YNH (sorry if I should know...) and what's in Custom.php? Jonathan3 (talk) 18:31, 4 September 2022 (UTC)
- YNH is Yunohost. I installed mediawiki via Yunohost. Custom.php contains:
$wgScriptPath = "";$wgArticlePath = "/$1";$wgUsePathInfo = true;$wgScriptExtension = ".php";$wgServer = "https://joinfediverse.wiki";- Yesterday YNH suddenly stopped working because of misconfigured nginx. I had to remove the whole server { ... } block to make it work again. Apparently the correct file to edit when installed with YNH is not /etc/nginx/nginx.conf but /etc/nginx/conf.d/joinfediverse.wiki.conf, which I will edit today while someone explains to me how via jitsi. PKFP (talk) 10:11, 5 September 2022 (UTC)
- Okay so what did the trick was to change a rewrite in /etc/nginx/conf.d/joinfediverse.wiki.d/mediawiki.conf
- Instead of rewrite ^//(.*)$ //index.php?title=$1&$args;
- it now reads rewrite ^(.*)$ //index.php?title=$1&$args;
- The only difference to before is that now the about page and other meta pages are no longer found under e.g. Meta:About, but Join the Fediverse:About. But that's just a minor inconvenience I can live with. PKFP (talk) 06:30, 6 September 2022 (UTC)
[MW 1.38.2] Extension:Popups preview text is blue; how can I change it to black?
Title says enough. The text on my page preview popups is blue. I've found absolutely nothing regarding this subject online, so thought I might be able to get some answers here. How do I fix this? 2A00:23C7:4410:6F01:ADD5:F3C1:2ADB:7BC (talk) 23:32, 29 August 2022 (UTC)
- Does it happen on the source editor or the visual editor? Jan Honvehlmann (talk) 23:51, 29 August 2022 (UTC)
- Neither. I'm talking about the Popups extension you can use to view page previews when you hover over a link. 2A00:23C7:4410:6F01:ADD5:F3C1:2ADB:7BC (talk) 00:13, 30 August 2022 (UTC)
- Perhaps you can change it using some custom CSS (cascading style sheet). But other than that, you might have to reach out to the developers of the extension. Jan Honvehlmann (talk) 00:27, 30 August 2022 (UTC)
- Ok, thanks 2A00:23C7:4410:6F01:ADD5:F3C1:2ADB:7BC (talk) 01:16, 30 August 2022 (UTC)
- Community? 2A00:23C7:4410:6F01:ADD5:F3C1:2ADB:7BC (talk) 16:43, 30 August 2022 (UTC)
- Community! Malyacko (talk) 19:27, 30 August 2022 (UTC)
- Title does not say enough. Please see "Post a new question" in the sidebar, plus provide the version info of the extension, plus if possible a link to where this problem can be seen, and/or link to a screenshot of the problem. Text is black on English Wikipedia for me, is it also for you?
- (PS: Why do you post unclear one-word comments like "Community?") Malyacko (talk) 19:32, 30 August 2022 (UTC)
- I just do that to bump the post after a period of inactivity.
- And yes, on Wikipedia it is black 2A00:23C7:4410:6F01:FDA3:42BB:66DE:F610 (talk) 20:10, 30 August 2022 (UTC)
- Please do not bump after 15 hours only. I've requested this before.
- Please read my previous comment again. Thanks. Malyacko (talk) 13:30, 31 August 2022 (UTC)
Incorrect time stamps of file revisions – intentional?
Earlier revisions of files have a time stamp and an exclamation mark before the file name. I have noticed that that time stamp is actually the upload time of the next newer version, not of itself.
Is that intentional? Jan Honvehlmann (talk) 23:50, 29 August 2022 (UTC)
- Yes Bawolff (talk) 06:01, 30 August 2022 (UTC)
- I see. And what is the benefit of it?
- It appears rather confusing if the time stamp in the revision file name is not its actual upload date. Jan Honvehlmann (talk) 21:28, 11 September 2022 (UTC)
- Someone made a decision 20 years ago, and it doesn't really seem worth the effort to change. Bawolff (talk) 22:16, 11 September 2022 (UTC)
No "Download Pdf" option in custom namespace
I recently rearranged my content into different namespaces. However, in custom namespaces the "Download Pdf" option does not show. It only shows in Main namespace. How do I enable it in custom namespaces?
I am using MediaWiki latest version, Php 7.4, Minerva skin with MobileFrontend extension. Sydchako (talk) 06:07, 30 August 2022 (UTC)
- Minerva has `$wgMinervaDownloadNamespaces` config option. It seems to be undocumented, but you can see the default value here. You should extend that to add your namespaces in LocalSettings.php file. – Ammarpad (talk) 18:43, 30 August 2022 (UTC)
Blank Website after an upgrade.
Hello everyone,
I got a problem after an update from MW 1.30.1 to MW 1.38. Here the history.
First of all, I've read the upgrade page, and I have a save of my database on 1.30 and on 1.35. It is important for the next steps.
In that page, I've read that I need to do a update to a version before 1.36, before updating to 1.38. So this is what I did. The updating on 1.35.7 were easy and everything (except some model needed to be fixed) work fine.
So, I try to update in 1.38. Trough the update page of my website, everything works, except that I had a skin issue, that I try to solve. For that, I use many solution that I found on Google (and mainly that was page directly coming from here).
It never worked. So I did (probably a mistake), an upload of my old database (in 1.30.1) and my old backups. But nothing worked. So I try do redo the update to 1.35.7, and I can go to the update page. Yeah. After fixing another skin problem (by erased
wfLoadSkin( 'Athena' ); wfLoadSkin( 'MinervaNeue' ); wfLoadSkin( 'MonoBook' ); wfLoadSkin( 'Timeless' );wfLoadSkin( 'Vector' ); form my LocalSetting.php) It worked and I could upgrade to 1.35.7. I could have access to my index. (I need to say that I've done exactly the same for all extensions).
But (because this is not the end), I got a message indicating that I miss skins. I put back the code in LocalSetting.php. And there, a blank page. I don't even have something to see on that page. Even the address (that is usually http://hirder.be/wiki/index.php?title=Accueil) doesn't show up. It stay at index.php.
It is important to me to have access to this because it is almost two years of work that could be gone to ashes.
For further information :
I used 1.30.1 before upgrading. Now I'm on 1.35.7.
PHP is 8.1
MySql version in 5.7 2A02:A020:E0:883E:80E4:4A12:1AC9:CD69 (talk) 09:34, 30 August 2022 (UTC)
- That part of the upgrade page is worded so badly that I can't understand it enough to improve. But I don't think it means you can't upgrade straight from 1.30 to 1.38. Jonathan3 (talk) 10:20, 30 August 2022 (UTC)
- Upgrading is a pain so why not just stay on 1.35 (LTS) for now and wait for 1.39, the next LTS version? See Version lifecycle. Jonathan3 (talk) 10:23, 30 August 2022 (UTC)
- That what I want. To stay in 1.35.7 because it worked. But now, it doesn't and I don't know why. In case of I have no solution here, I'll will do a Hard reset, but it is two years of work gone to ashes. 109.139.12.9 (talk) 14:45, 30 August 2022 (UTC)
- did you upgrade skins to right version?
- Are there errors in php error log (see How to debug) Bawolff (talk) 16:51, 30 August 2022 (UTC)
- I erased all the files in the folder and then upload the new ones. But it seems to keep going buggy.
- And now this not really the problem. I don’t see anything on my index.php page. Juste take a look at the link I posted earlier
- (Yes it is still me, but I use different device) 2A02:A020:A3:A8AA:59EC:B6ED:B138:BFFC (talk) 17:42, 30 August 2022 (UTC)
- Did you backup at 1.35.7 before the failed upgrade (or at any point)? If you did you could go back and try again. Jonathan3 (talk) 18:08, 30 August 2022 (UTC)
- I have a backup on 1.30.1 from files and database. I can do a backup on my ftp server. Do I need to erased all files (and database) to do so properly? 2A02:A020:A3:A8AA:59EC:B6ED:B138:BFFC (talk) 18:28, 30 August 2022 (UTC)
- blank page usually means php error when error reporting has been disabled. I would generally suggest trying to figure out what the error is (see How to debug) so you can avoid whatever the error is Bawolff (talk) 19:24, 30 August 2022 (UTC)
- Hello ! This is me again. So, I used the Debug page (thanks again). I got a first errors of extensions, about AbuseFilter. This was not present in my extension folder, so I juste erased it from my
LocalSetting.php. - I reload the page, and here what I got :
- Deprecated: preg_match(): Passing null to parameter #2 ($subject) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/lbfactory/LBFactory.php on line 762
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 263
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Warning: session_name(): Session name cannot be changed after headers have already been sent in /home/hirderr/www/wiki/includes/Setup.php on line 712
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 263
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Warning: session_id(): Session ID cannot be changed after headers have already been sent in /home/hirderr/www/wiki/includes/session/SessionBackend.php on line 796
- Warning: session_id(): Session ID cannot be changed after headers have already been sent in /home/hirderr/www/wiki/includes/Setup.php on line 756
- Warning: session_start(): Session cannot be started after headers have already been sent in /home/hirderr/www/wiki/includes/Setup.php on line 757
- Deprecated: strtr(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/Title.php on line 424
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: str_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /home/hirderr/www/wiki/includes/libs/objectcache/MediumSpecificBagOStuff.phpon line 893
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Warning: Cannot modify header information - headers already sent by (output started at /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php:579) in /home/hirderr/www/wiki/includes/libs/HttpStatus.php on line 112
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Deprecated: strlen(): Passing null to parameter #1 ($string) of type string is deprecated in /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php on line 579
- Warning: Cannot modify header information - headers already sent by (output started at /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php:579) in /home/hirderr/www/wiki/includes/WebResponse.php on line 74
- Warning: Cannot modify header information - headers already sent by (output started at /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php:579) in /home/hirderr/www/wiki/includes/WebResponse.php on line 74
- Warning: Cannot modify header information - headers already sent by (output started at /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php:579) in /home/hirderr/www/wiki/includes/WebResponse.php on line 74
- Warning: Cannot modify header information - headers already sent by (output started at /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php:579) in /home/hirderr/www/wiki/includes/WebResponse.php on line 74
- Warning: Cannot modify header information - headers already sent by (output started at /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php:579) in /home/hirderr/www/wiki/includes/WebResponse.php on line 74
Warning: Cannot modify header information - headers already sent by (output started at /home/hirderr/www/wiki/includes/libs/rdbms/database/Database.php:579) in /home/hirderr/www/wiki/includes/WebResponse.php on line 742A02:A020:A3:A8AA:6867:11FD:CFD9:8394 (talk) 08:02, 31 August 2022 (UTC)- So the deprecated warnings are known issues when running mediawiki with php 8.1. They are safe to ignore (if error reporting is turned off) and should be fixed in the upcoming mediawiki 1.38.3 or 1.39.0 release. Bawolff (talk) 19:03, 31 August 2022 (UTC)
- Ok thanks you !
- Now, what i've done, is a hard reste. Erased alll my database and my files from my servers. Then i re-upload my backups. I got this now :
Fatal error: Uncaught Exception: /home/hirderr/www/wiki/skins/MinervaNeue/skin.json does not exist! in /home/hirderr/www/wiki/includes/registration/ExtensionRegistry.php:107 Stack trace: #0 /home/hirderr/www/wiki/includes/GlobalFunctions.php(87): ExtensionRegistry->queue('/home/hirderr/w...') #1 /home/hirderr/www/wiki/LocalSettings.php(144): wfLoadSkin('MinervaNeue') #2 /home/hirderr/www/wiki/includes/Setup.php(94): require_once('/home/hirderr/w...') #3 /home/hirderr/www/wiki/includes/WebStart.php(88): require_once('/home/hirderr/w...') #4 /home/hirderr/www/wiki/index.php(39): require('/home/hirderr/w...') #5 {main} thrown in /home/hirderr/www/wiki/includes/registration/ExtensionRegistry.php on line 10791.181.192.22 (talk) 23:51, 31 August 2022 (UTC) - Update : I found what was going on. Some extensions was written on LocalSetting.php, but wasn't on the folder. i just delete the code that need it, and now, it works (but only in 1.30.12). I got other things to fix like this :
{#if: | <templatestyles src="Infobox/Pictogramme/{{{icon}}}.css"></templatestyles> }} Modèle:Langue{{#if:|{{#if:Modèle:Oui non|{{#invoke:Formatage du titre- |setDisplayTitle
- |lang=
- |italic=
- |options=noreplace
but everything works 91.181.192.22 (talk) 00:26, 1 September 2022 (UTC)- That error suggests you are missing extension:ParserFunctions and extension:Scribunto Bawolff (talk) 00:47, 1 September 2022 (UTC)
- (I've created an account).
- Those extension were activated in
LocalSettings.php. Seems like I had the same issues two years ago when I start my own wiki, on my computer instead of a true web server. I've put an answer to the topic over there. HirderWiki (talk) 22:09, 2 September 2022 (UTC)
- Sorry, but note that MediaWiki is not yet compatible with PHP 8 so please use PHP 7.3/7.4. 197.202.41.217 (talk) 18:06, 1 September 2022 (UTC)
- PHP version has nothing to do with the problem discussed in this thread. Malyacko (talk) 11:46, 2 September 2022 (UTC)
After migrating a on-prem mediawiki to conatiner i am getting a hook.php error
Warning: Parameter 2 to Cite::checkRefsNoReferences() expected to be a reference, value given in /var/www/html/includes/Hooks.php on line 201 Sandy0619 (talk) 12:19, 31 August 2022 (UTC)
- site is working fine but this message is showing,
- created a docker container and moved all on-prem files to azure file share, mounted it to docker container as /var/www/html, connected with PAAS mysql DB.
- any help on this would be great full. Thanks in advance, Sandy0619 (talk) 12:21, 31 August 2022 (UTC)
- Make sure that the Cite extension is the correct version for your version of mediawiki. Bawolff (talk) 18:59, 31 August 2022 (UTC)
- got cleared after running upgrade from mw-config, Thank you Sandy0619 (talk) 09:56, 16 September 2022 (UTC)
- Now the images are not loading, only image names are visble when site loads up.
- $wgEnableUploads = true;
- $wgUseImageMagick = true;
- $wgImageMagickConvertCommand = "/usr/bin/convert";
- $wgShowEXIF = function_exists( "exif_read_data" ); Sandy0619 (talk) 09:57, 16 September 2022 (UTC)
- below is site link.
- http://index.php/Main_Page Sandy0619 (talk) 09:58, 16 September 2022 (UTC)
- every thing was working when this was running azure containers, issues showed up after deploying in AKS cluster,
- Version 1.38.2 Sandy0619 (talk) 09:59, 16 September 2022 (UTC)
- error while loading image
- <img src="http://xx.xx.xx.xx/images/thumb/6/65/Dmpedia.jpg/400px-Dmpedia.jpg" alt="The image “http://xx.xx.xx.xx/images/thumb/6/65/Dmpedia.jpg/400px-Dmpedia.jpg” cannot be displayed because it contains errors."> Sandy0619 (talk) 11:26, 16 September 2022 (UTC)
- same images works good on on-prem mediawiki server. Sandy0619 (talk) 11:27, 16 September 2022 (UTC)
- The http header is mixed into the files. We have had previous reports of this with azure+apache - https://m.mediawiki.org/wiki/Project%3ASupport%20desk/Flow/2022/03#h-Images_corrupted_with_HTTP_response_headers-2022-03-16T19%3A26%3A00.000Z . People say disabling mmap and sendfile in your apache config might help. I.e.
- Bawolff (talk) 11:37, 16 September 2022 (UTC)
EnableSendfile Off EnableMMAP off
- That worked, thank you very much for your support Sandy0619 (talk) 13:26, 16 September 2022 (UTC)
- this change will be inside container? will this go after restart? Sandy0619 (talk) 12:07, 16 September 2022 (UTC)
- typically you have to tell apache to reload its config. A restart will definitely do it, but there should be a way to tell apache to reload config without restarting. Bawolff (talk) 22:04, 16 September 2022 (UTC)
- I thing need to build a custom image setting this in apache2.conf so that things don't change after restart. or do we have any custom images build like that?Sandy0619 (talk) 15:09, 19 September 2022 (UTC)
EnableSendfile Off EnableMMAP off
- Building a custom image is probably your best bet. Bawolff (talk) 00:03, 20 September 2022 (UTC)
- Hello - I am also up against the same issue as Sandy - we are also on version 1.82.2 - glad to find this post 73.9.207.159 (talk) 12:30, 16 September 2022 (UTC)
- Sorry 1.38.2 73.9.207.159 (talk) 12:30, 16 September 2022 (UTC)
Auto-creation of redirect pages
Hello. I was wondering if anyone knew a way to automatically create redirection pages from a list of synonyms. For instance, if my wiki had a "Poney" page and I registered "Shettland Poney" as a synonym, could I make it so the page "Shettland Poney" is created automatically and points to the "Poney" one? LMamo (talk) 15:26, 31 August 2022 (UTC)
- not easily. You could use pywikibot Bawolff (talk) 00:43, 3 September 2022 (UTC)
- Thank you! I'll look into it LMamo (talk) 07:19, 7 September 2022 (UTC)