Project:Support desk

About this board

Welcome to the MediaWiki Support desk, where you can ask MediaWiki questions!

(Read this message in a different language)

See also

Before you post

Post a new question

  1. To help us answer your questions, please indicate which versions you are using, as found on your wiki's Special:Version page:
    • MediaWiki version
    • PHP version
    • Database type and version
  2. Please include the web address (URL) to your wiki if possible. It's often easier for us to identify the source of the problem if we can see the error directly.
  3. To start a new thread, click "Start a new topic".

Url Duplicated When Save Changes.

1
Sergiobetween (talkcontribs)

I have my Wikipedia, in url


http://guru-praia.miwikipedia.com/gurupraia

When i editing any article, and clic save, the page go to:

http:guru-praia.miwikipedia.com/gurupraia/guru-praia.miwikipedia.com/gurupraia


and obviously:

Not Found

The requested URL was not found on this server.


Somebody knows whats could happening?

Reply to "Url Duplicated When Save Changes."

Problems with updating Mediawiki LDAP

4
MSchmitt0815 (talkcontribs)

I am trying updating LDAP. Having difficulty understanding what belongs where and how... following the Description as good as i can.

Please Help.

When i run the maintenance/update.php script it says to me Found invalid JSON in file: /var/www/html/ldap.json

At the end of the Script it prints:

BadMethodCallException from line 506 of /var/www/html/mediawiki/includes/session/SessionProvider.php: MediaWiki\Session\SessionProvider::preventSessionsForUser must be implemented when canChangeUser() is false

#0 /var/www/html/mediawiki/includes/session/SessionManager.php(453): MediaWiki\Session\SessionProvider->preventSessionsForUser()

#1 /var/www/html/mediawiki/includes/user/User.php(886): MediaWiki\Session\SessionManager->preventSessionsForUser()

#2 /var/www/html/mediawiki/extensions/AbuseFilter/includes/FilterUser.php(57): MediaWiki\User\User::newSystemUser()

#3 /var/www/html/mediawiki/extensions/AbuseFilter/includes/FilterUser.php(48): MediaWiki\Extension\AbuseFilter\FilterUser->getUser()

#4 /var/www/html/mediawiki/extensions/AbuseFilter/maintenance/NormalizeThrottleParameters.php(151): MediaWiki\Extension\AbuseFilter\FilterUser->getUserIdentity()

#5 /var/www/html/mediawiki/extensions/AbuseFilter/maintenance/NormalizeThrottleParameters.php(484): MediaWiki\Extension\AbuseFilter\Maintenance\NormalizeThrottleParameters->normalizeParameters()

#6 /var/www/html/mediawiki/maintenance/includes/LoggedUpdateMaintenance.php(49): MediaWiki\Extension\AbuseFilter\Maintenance\NormalizeThrottleParameters->doDBUpdates()

#7 /var/www/html/mediawiki/maintenance/update.php(197): LoggedUpdateMaintenance->execute()

#8 /var/www/html/mediawiki/maintenance/includes/MaintenanceRunner.php(703): UpdateMediaWiki->execute()

#9 /var/www/html/mediawiki/maintenance/doMaintenance.php(100): MediaWiki\Maintenance\MaintenanceRunner->run()

#10 /var/www/html/mediawiki/maintenance/update.php(298): require_once('/var/www/html/m...')

#11 {main}

PHP Notice:  Uncommitted DB writes (transaction from MediaWiki\Extension\AbuseFilter\Maintenance\NormalizeThrottleParameters::doDBUpdates) in /var/www/html/mediawiki/includes/libs/rdbms/database/TransactionManager.php on line 586

PHP Notice:  DB transaction writes or callbacks still pending (MediaWiki\Auth\TemporaryPasswordPrimaryAuthenticationProvider::providerChangeAuthenticationData, MediaWiki\Auth\LocalPasswordPrimaryAuthenticationProvider::providerChangeAuthenticationData, MediaWiki\User\User::saveSettings, MediaWiki\User\User::saveSettings, MediaWiki\User\User::clearSharedCache) in /var/www/html/mediawiki/includes/libs/rdbms/database/Database.php on line 3344


My ldap.json:

1 {

"internet.adress": {

¦ "connection": {

¦ ¦ "server": "First-Domain-Controller",

¦ ¦ "port": "389",

¦ ¦ "user": "CN=firstUser,OU=Device-User,OU=Benutzer,Some=SomeUser,One=OneUser",

¦ ¦ "pass": "SomeChars",

¦ ¦ "enctype": "clear",

¦ ¦ "options": {

¦ ¦ ¦ "LDAP_OPT_DEREF": 1

¦ ¦ },

¦ ¦ "basedn": "Some=SomeUser, One=OneUser",

¦ ¦ "userbasedn": "OU=Benutzer,Some=SomeUser,One=OneUser",

¦ ¦ "groupbasedn": "OU=SafetyGroups,Some=SomeUser,One=OneUser",

¦ ¦ "searchattribute": "samaccountname",

¦ ¦ "usernameattribute": "samaccountname",

¦ ¦ "realnameattribute": "cn",

¦ ¦ "emailattribute": "mail",

¦ ¦ "grouprequest": "MediaWiki\\Extension\\LDAPProvider\\UserGroupsRequest\\UserMemberOf::factory",

¦ ¦ "presearchusernamemodifiers": [ "spacestounderscores", "lowercase" ],

¦ ¦ "SyncMechanismRegistry": {

¦ ¦ ¦ ¦ "mappedgroups": "MediaWiki\\Extension\\LDAPGroups\\SyncMechanism\\MappedGroups::factory",

¦ ¦ ¦ ¦ ¦ "allgroups": "MediaWiki\\Extension\\LDAPGroups\\SyncMechanism\\AllGroups::factory"

¦ ¦ }

¦ },

¦ "userinfo": [],

¦ "authorization": []

}

}

For more Information just ask.

Greetings

Malyacko (talkcontribs)

Which exact MediaWiki version? Which exact version of which exact extension related to LDAP?

MSchmitt0815 (talkcontribs)

MediaWiki Version: 1.41

The Extension would be LDAPAuthentication2 Version: 1.39 and LDAPProvider Version: 1.39

MSchmitt0815 (talkcontribs)

Thanks for the fast reply!!!

Reply to "Problems with updating Mediawiki LDAP"

Visual Editor doesn't work after update

3
Kryptator (talkcontribs)

After I updated to 1.4.1 (from 1.3.9), everything works except the Visual Editor.

No error message appears either. When I click on 'edit', the loading bar appears briefly and then nothing else happens. From there, I cannot go directly to edit source, nothing happens. However, using edit source directly works.

I use the Timeless skin, so I thought that was the problem. So I switched to Vector as a test, with the same result.

Does anyone have any advice on how I can fix this?

Malyacko (talkcontribs)

I hope you upgraded from 1.39 to 1.41 and not the ancient versions you mentioned above. For the start, check your web browser's error console and check your web server's error logs.

Kryptator (talkcontribs)

Of course. :)

I reinstalled cite & visual editor and know it seems to work :)

Thanks!

Reply to "Visual Editor doesn't work after update"

Is it okay to create my own page about myself instead of Wikipedia?

5
JayAndrewBoy (talkcontribs)

Hi there!

I just signed up for MediaWiki and I'm hoping to create a page about myself. I'd like a place to share information without disruption.

Unfortunately, Wikipedia has deleted my user page.

So I was wondering if it's okay to create my own page here on MediaWiki instead?

I'm waiting for your replies! :)

Malyacko (talkcontribs)

Hi and welcome. No, it is not okay as we are not a place to host random content. Please see Project:About - thanks! (You are always free to host your own website about yourself on your own server.)

Bawolff (talkcontribs)
JayAndrewBoy (talkcontribs)

Really? How does it work? 🤔

Malyacko (talkcontribs)

Click that link and find out.

Reply to "Is it okay to create my own page about myself instead of Wikipedia?"

mediawiki dropping domain URL

2
ArchATempAcct (talkcontribs)

When I type "blahblahwiki.org" into my browser's address bar, it takes me to my wiki ok, but the domain name is replaced with the path to the folder the wiki is residing in.

So "blahblahwiki.org/Main_Page" becomes "https://umbrelladomain.com/blahblahwiki/index.php/Main_Page"

Since I could make it do that without buying a domain name I went to my new hosting provider and asked what's broken.

"I want blahblahwiki to have http://umbrelladomain/blahblawiki as it's root folder. I just can't get it to say "blahblahwiki.org" in the browser address bar. "

Their response:

"The domain (Blahblahwiki.org) is a addon domain that points to the public_html/blahblahwiki folder.

There is no redirect in the .htaccess file, which means the redirect is most likely caused by the script that you are using in public_html/blahblahwiki.

To which I replied:

"Thank you, I will take this to the Mediawiki people and ask them what it might be.

To be clear, something in the /blahblahwiki folder is making it redirect back into the same folder, causing it to drop the blahblahwiki.org and instead use the umbrelladomain/blahblahwiki folder address.

If I have that incorrect, let me know. I will take this up with mediawiki now.

Thank you so very much, guys!"

They confirmed:

"Correct, if you have any other questions please let us know."

So thats what brought me here. I checked out the short-URL help text, but nothing there applied to the situation. I tried the autimatic htaccess configurator too. I played around with the path variables in the  localsettings script.

What could be overriding my domain name?

TheDJ (talkcontribs)

My first guess is that you haven't updated your LocalSettings.php to make use of the new domain.

Reply to "mediawiki dropping domain URL"

A few days ago a new web page blew onto my homepage and each day it became more aggressive taking over my communiations. I do not like this "overlook" and want it gone. Please help."

2
Jackatwood (talkcontribs)

I need to rid myself of overlook. It is rude and assumes too much.

TheDJ (talkcontribs)

it sounds like you have been hacked. Contact your system administrator to secure your website.

Reply to "A few days ago a new web page blew onto my homepage and each day it became more aggressive taking over my communiations. I do not like this "overlook" and want it gone. Please help.""

How to access page name and URL from within LocalSettings.php?

5
Sampson2023 (talkcontribs)

I am using a $wgHooks to insert some meta information in the <HEAD> section of the page.

How can I access the page's title and URL from within LocalSettings.php?

Bawolff (talkcontribs)

It can vary depending on hook but generally:

RequestContext::getMain()->getTitle()->getFullUrl()

RequestContext::getMain()->getTitle()->getPrefixedText()


(In a future version you might have to use \MediaWiki\Context\RequestContext::getMain()->getTitle()->getFullUrl() instead)

Sampson2023 (talkcontribs)

That's amazing, it worked! Many thanks :-)

How about getting the revision timestamp, in the same way?

Bawolff (talkcontribs)

Its more complicated... you'd have to do something like MediaWiki\MediawikiServices->getRevisionLookop()->getRevisionByTitle( RequestContext::getMain()->getTitle() )->getTimestamp();

The timestamp would be in machine format so you would need to format it with RequestContext::getMain()->getLanguage()->timeanddate() if you want it based on user preference, or wfTimestamp() if you need a specific format.


I didn't test any of this, so it might be slightly off, but should be roughly right.

There are docs for mediawiki classes at https://doc.wikimedia.org/mediawiki-core/master/php/ the classes i have mentioned are RequestContext, Title, RevisionRecord, RevisionLookup, Language

Sampson2023 (talkcontribs)

Brilliant, I got it working, thank you so much!

Reply to "How to access page name and URL from within LocalSettings.php?"

Upgrade advice for v1.26 -> 1.41

2
Docwikinoob (talkcontribs)

Current Version : Bitnami MediaWiki 1.26

OS : Windows Server 2012 R2

would like to move to

New Version : 1.41

OS : Windows Server 2022

review the following items:

- Manual:Upgrading

- MediaWiki 1.35

I tried the following so far:

1) Upgraded xampp which didn't work

2) tried to upgrade 1.35 and it didn't work

TheDJ (talkcontribs)

Does not do what ? We cant guess for a cause based on a guess of the problem. Did you check logfiles and command output for any errors ? Did you follow the upgrade guide and at which step did you get stuck ?

Reply to "Upgrade advice for v1.26 -> 1.41"
Sue8183 (talkcontribs)

I put some notes in Sandbox about Harriett Cater, I now cant find these notes - not sure what I am doing wrong

Tropicalkitty (talkcontribs)

You had posted it on Meta… in the wrong place.

2A02:C7C:64FD:7C00:2919:648B:E59E:7FC8 (talkcontribs)

Thank you so much I am gradually getting myself sorted out,

Reply to "Lost in Sandbox"

Disable hiding the sidebar for anonymous users in Vector 2022

2
193.77.83.38 (talkcontribs)

Hi,

I want to change default Vector 2022 behavior for anonymous users and make is the same as for logged in users. By default, wiki hides the sidebar with every new page load, and displays the TOC. We want to achieve the following: - Keep the sidebar open by default - Keep the table of contents hidden by default

Failing that, is there any way to maybe move the table of contents back inline (into main content area, as it was in the previous version of Vector) or maybe push the table of contents under the sidebar? We created custom navigation for our wiki content and placed in the sidebar, but we need to keep the sidebar open for users. What can we do to keep the sidebar and do something to move the TOC out of the way?

86.61.27.128 (talkcontribs)

Is there maybe any code I can put in common.js to override the defaults?

Reply to "Disable hiding the sidebar for anonymous users in Vector 2022"