Hi there,
I installed mediawiki 1.17 and this extension: http://www.mediawiki.org/wiki/Extension:NiceCategoryList2/2.2
Then I get the messages:
---------- Warning: in_array() [function.in-array]: Wrong datatype for second argument in /var/www/web468/html/psych-med.de/wiki/includes/parser/ParserOptions.php on line 317
Warning: Cannot modify header information - headers already sent by (output started at /var/www/web468/html/psych-med.de/wiki/LocalSettings.php:1) in /var/www/web468/html/psych-med.de/wiki/includes/WebResponse.php on line 22 ----------
The first message I get also when I install the Cite-Extension.
I tried the bugfix from http://tinyurl.com/5ty87af
but that didn't change anything.
Any idea what's wrong?
Daniel
Daniel Walz wrote:
Hi there,
I installed mediawiki 1.17 and this extension: http://www.mediawiki.org/wiki/Extension:NiceCategoryList2/2.2
Then I get the messages:
Warning: in_array() [function.in-array]: Wrong datatype for second argument in /var/www/web468/html/psych-med.de/wiki/includes/parser/ParserOptions.php on line 317
Warning: Cannot modify header information - headers already sent by (output started at /var/www/web468/html/psych-med.de/wiki/LocalSettings.php:1) in /var/www/web468/html/psych-med.de/wiki/includes/WebResponse.php on line 22
The first message I get also when I install the Cite-Extension.
I tried the bugfix from http://tinyurl.com/5ty87af
but that didn't change anything.
Really? That change (you may see it easier at [1]) seems to be the only way to pass a datatype there. I don't even see how NiceCategoryList2 could be affect to make the bug.
1- http://www.mediawiki.org/wiki/Special:Code/MediaWiki/93626
Platonides schrieb am 14.09.2011 23:07:
Daniel Walz wrote:
Hi there,
I installed mediawiki 1.17 and this extension: http://www.mediawiki.org/wiki/Extension:NiceCategoryList2/2.2
Then I get the messages:
Warning: in_array() [function.in-array]: Wrong datatype for second argument in /var/www/web468/html/psych-med.de/wiki/includes/parser/ParserOptions.php on line 317
Warning: Cannot modify header information - headers already sent by (output started at /var/www/web468/html/psych-med.de/wiki/LocalSettings.php:1) in /var/www/web468/html/psych-med.de/wiki/includes/WebResponse.php on line 22
The first message I get also when I install the Cite-Extension.
I tried the bugfix from http://tinyurl.com/5ty87af
but that didn't change anything.
Really? That change (you may see it easier at [1]) seems to be the only way to pass a datatype there. I don't even see how NiceCategoryList2 could be affect to make the bug.
1- http://www.mediawiki.org/wiki/Special:Code/MediaWiki/93626
There is a little difference: In the link I posted, it is
if ( !isset( $this->mAccessedOptions ) ) { return array(); // BUGFIX: return empty array !! return false;
In the official link you posted it is
if ( !isset( $this->mAccessedOptions ) ) { return false; return array();
So the order of the returns is reversed.
Anyway, I forgot to "purge" the cache, now the bug is fixed. Thanks!
Daniel
Daniel Walz wrote:
There is a little difference: In the link I posted, it is
if ( !isset( $this->mAccessedOptions ) ) { return array(); // BUGFIX: return empty array !! return false;
In the official link you posted it is
if ( !isset( $this->mAccessedOptions ) ) { return false; return array();
So the order of the returns is reversed.
In the link I posted it was a diff, so - return false; + return array(); means to remove the first return and add the second one.
Which is equivalent to put the added return before the old (which would then never be reached).
Anyway, I forgot to "purge" the cache, now the bug is fixed. Thanks!
Daniel
I'm glad it turned out to be just that.
Daniel Walz schrieb am 12.09.2011 20:38:
Hi there,
Warning: Cannot modify header information - headers already sent by (output started at /var/www/web468/html/psych-med.de/wiki/LocalSettings.php:1) in /var/www/web468/html/psych-med.de/wiki/includes/WebResponse.php on line 22
It was a missing ?> in both LocalSettings.php and the extension.
Daniel
Daniel Walz schrieb:
Daniel Walz schrieb am 12.09.2011 20:38:
Hi there,
Warning: Cannot modify header information - headers already sent by (output started at /var/www/web468/html/psych-med.de/wiki/LocalSettings.php:1) in /var/www/web468/html/psych-med.de/wiki/includes/WebResponse.php on line 22
It was a missing ?> in both LocalSettings.php and the extension.
Daniel
?> at end of file is optional. Looks more like having something before the <?php of LocalSettings (a BOM mark, perhaps).
mediawiki-l@lists.wikimedia.org