Last modified: 2010-05-15 15:41:07 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 7526 - $wgDefaultUserOptions['editsection'] = 0 does not work
$wgDefaultUserOptions['editsection'] = 0 does not work
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
Parser (Other open bugs)
1.7.x
All All
: Normal normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2006-10-09 06:45 UTC by Heinz-Josef Lücking
Modified: 2010-05-15 15:41 UTC (History)
0 users

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Heinz-Josef Lücking 2006-10-09 06:45:44 UTC
MediaWiki 1.71
Function initialiseFromUser( &$userInput ) {
Line 4591

     $this->mEditSection = true;

meaning imho that by default the possibility to edit section is set to 
true. I think this is a reason why in LocalSettings.php

     $wgDefaultUserOptions['editsection'] = 0

does'nt work (It did not in my wiki).


In MediaWiki 1.46 you can find the line.

     $this->mEditSection = $user->getOption( 'editsection' );

Here the possibility to edit section is defined by LocalSettings.php.

I used this lines for my purpose

    if ($user->getID()) {
       $this->mEditSection = $user->getOption( 'editsection' );
    } else {
       $this->mEditSection = 0;
    }

by Zigger, from (http): 
mail.wikipedia.org/pipermail/mediawiki-l/2004-November/002099.html


HeinzJ
Comment 1 Dan Li 2006-10-09 06:48:39 UTC
By the way, this does not affect 1.8, AFAIK.
Comment 2 Brion Vibber 2006-10-09 08:19:46 UTC
$wgDefaultUserOptions appears to be used anywhere by MediaWiki, which
would explain why it doesn't work. :)

Fixed in r16884.
Comment 3 Dan Li 2006-10-10 03:37:55 UTC
Sweet, I don't need to use an extension function to set defaults any more (since
the advertised UserDefaultOptions hook didn't exist either o_O).

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links