[MediaWiki-l] Why do I get deprecated functions?

Kevin Israel pleasestand at live.com
Mon Nov 3 14:55:57 UTC 2014

On 11/03/2014 08:40 AM, Katharina Wolkwitz wrote:
> Hi everybody,
> here's something I don't understand.
> I've just updated my mediawiki-installation to the current version 1.23.5 -
> which I thought was up to date, and now I'm running up against one error-message
> after the other with deprecated functions like this one:
> Deprecated: preg_replace(): The /e modifier is deprecated, use
> preg_replace_callback instead in
> /opt/lampp/htdocs/_fhbwiki/includes/GlobalFunctions.php on line 1271

You are not actually running MediaWiki 1.23. As far as I know, MediaWiki
1.22 and later no longer use the deprecated /e modifier (though some
extensions might).

Not running the version of MediaWiki you think you are would also
explain your "Call to undefined method SpecialRenameuser::getOutput()"

> And also this:
> Strict Standards: Non-static method Mail::factory() should not be called
> statically in /opt/lampp/htdocs/_fhbwiki/includes/UserMailer.php on line 154
> or this:
> Strict Standards: Non-static method PEAR::isError() should not be called
> statically, assuming $this from incompatible context in
> /opt/lampp/lib/php/Net/SMTP.php on line 450

This was partially fixed in MediaWiki 1.17. To silence the remaining
warnings (tracked as [bug 47463][1]), you can change PHP's
[error_reporting][2] INI setting.

[1]: https://bugzilla.wikimedia.org/show_bug.cgi?id=47463

Kevin Israel - MediaWiki developer, Wikipedia editor

More information about the MediaWiki-l mailing list