About this board

Extension LastUserLogon not working in Mediawiki 1.27 anymore, but solution...

3
DikkieDick (talkcontribs)

When using this extension in MediaWiki 1.27 a blank screen shows up and error_log says:

[Fri Sep 09 13:40:27 2016] [error] [client 10.10.10.50] PHP Fatal error:  Call to undefined method User::getSkin() in /u01/mediawiki/extensions/LastUserLogin/LastUserLogin.body.php on line 113, referer: http://10.10.10.100/index.php/Special:SpecialPages

Seems that getSkin() is deprecated. I solved this by commenting line 113 and adding a new line 113:

$userName = $row[ $key] ;

That seems to do the trick and shows the username, realname and lastlogin.

128.252.214.219 (talkcontribs)

Which version are you using? Thanks.

DikkieDick (talkcontribs)

Version 1.3 of April 7th, 2015, which is the most recent version.

Reply to "Extension LastUserLogon not working in Mediawiki 1.27 anymore, but solution..."

Special:ListUsers -> contribs throws an exception

1
DikkieDick (talkcontribs)

When in Special:ListUsers you can click on contribs to see what the user has contributed, but this gives the following exception:

(replaced the username with <username> below.

Exception encountered, of type "InvalidArgumentException"

[f16de82ee9227a9173d25e69] /index.php/Special:Contributions/<username> InvalidArgumentException from line 246 of /u01/mediawiki/includes/Message.php: $key must be a string or an array

Backtrace:

#0 /u01/mediawiki/includes/GlobalFunctions.php(1391): Message->__construct(NULL, array)

#1 /u01/mediawiki/includes/changes/ChangesList.php(203): wfMessage(NULL)

#2 /u01/mediawiki/includes/specials/pagers/ContribsPager.php(451): ChangesList::flag(string)

#3 /u01/mediawiki/includes/pager/IndexPager.php(442): ContribsPager->formatRow(stdClass)

#4 /u01/mediawiki/includes/specials/SpecialContributions.php(204): IndexPager->getBody()

#5 /u01/mediawiki/includes/specialpage/SpecialPage.php(479): SpecialContributions->execute(string)

#6 /u01/mediawiki/includes/specialpage/SpecialPageFactory.php(576): SpecialPage->run(string)

#7 /u01/mediawiki/includes/MediaWiki.php(282): SpecialPageFactory::executePath(Title, RequestContext)

#8 /u01/mediawiki/includes/MediaWiki.php(745): MediaWiki->performRequest()

#9 /u01/mediawiki/includes/MediaWiki.php(519): MediaWiki->main()

#10 /u01/mediawiki/index.php(43): MediaWiki->run()

#11 {main}

Running MediaWiki 1.27.1 with php 5.6.17.

When I wanted to check contribs for user Admin when logged in as user Admin it showed the contributions so I thought it could be a security-issue, so I tried with my username and was also only able to see the contribs of Admin.

So I did another test with another user which only contained letters and then it doesn't throw an error. It seems only to result in an error when the username is in the format AB012345, so first a few letters followed by numbers.

Reply to "Special:ListUsers -> contribs throws an exception"
There are no older topics