Page MenuHomePhabricator

[BetaFeatures] Fatal error: Declaration of HTMLFeatureField::getInputHTML($value) must be compatible with NewHTMLCheckField::getInputHTML($value, $attr = NULL)
Closed, ResolvedPublic

Description

Today, I upgraded php7.1 to php7.2. Page tell me:

Fatal error: Declaration of HTMLFeatureField::getInputHTML($value) must be compatible with NewHTMLCheckField::getInputHTML($value, $attr = NULL) in /InstallPath/w/extensions/BetaFeatures/includes/HTMLFeatureField.php on line 26

I can promise that I haven't edit any files.

I try to fix this error, then I solved this error:
I modified the parameter of getInputHTML() method to

function getInputHTML( $value, $attr = NULL ) {

on includes/HTMLFeatureField.php in 283 line.
My wiki info are:

MediaWiki1.29.1
PHP7.2.0 (cgi-fcgi)
MariaDB10.2.10-MariaDB-log
ICU52.1
Lua5.1.5

Event Timeline

RazeSoldier renamed this task from Fatal error: Declaration of HTMLFeatureField::getInputHTML($value) must be compatible with NewHTMLCheckField::getInputHTML($value, $attr = NULL) to [BetaFeatures] Fatal error: Declaration of HTMLFeatureField::getInputHTML($value) must be compatible with NewHTMLCheckField::getInputHTML($value, $attr = NULL).Dec 1 2017, 5:19 PM

Thanks for taking a look at the code and reporting this!

You are very welcome to use developer access to submit the proposed code changes as a Git branch directly into Gerrit which makes it easier to review them quickly and provide feedback.
If you don't want to set up Git/Gerrit, you can also use the Gerrit Patch Uploader. Thanks again!

Change 394739 had a related patch set uploaded (by 星耀晨曦; owner: 星耀晨曦):
[mediawiki/extensions/BetaFeatures@master] Compatible with php7.2

https://gerrit.wikimedia.org/r/394739

RazeSoldier renamed this task from [BetaFeatures] Fatal error: Declaration of HTMLFeatureField::getInputHTML($value) must be compatible with NewHTMLCheckField::getInputHTML($value, $attr = NULL) to [BetaFeatures] Fatal error: Declaration of HTMLFeatureField::getInputHTML($value) must be compatible with NewHTMLCheckField::getInputHTML($value, $attr = NULL) in PHP 7.2.Dec 2 2017, 4:15 PM
Reedy renamed this task from [BetaFeatures] Fatal error: Declaration of HTMLFeatureField::getInputHTML($value) must be compatible with NewHTMLCheckField::getInputHTML($value, $attr = NULL) in PHP 7.2 to Fatal error: Declaration of HTMLFeatureField::getInputHTML($value) must be compatible with NewHTMLCheckField::getInputHTML($value, $attr = NULL).Dec 3 2017, 12:13 AM

Change 394739 merged by jenkins-bot:
[mediawiki/extensions/BetaFeatures@master] Compatible with php7.2

https://gerrit.wikimedia.org/r/394739

RazeSoldier renamed this task from Fatal error: Declaration of HTMLFeatureField::getInputHTML($value) must be compatible with NewHTMLCheckField::getInputHTML($value, $attr = NULL) to [BetaFeatures] Fatal error: Declaration of HTMLFeatureField::getInputHTML($value) must be compatible with NewHTMLCheckField::getInputHTML($value, $attr = NULL).Dec 5 2017, 8:22 AM

Change 427533 had a related patch set uploaded (by Paladox; owner: RazeSoldier):
[mediawiki/extensions/BetaFeatures@REL1_30] Compatible with php7.2

https://gerrit.wikimedia.org/r/427533

Change 427533 merged by jenkins-bot:
[mediawiki/extensions/BetaFeatures@REL1_30] Compatible with php7.2

https://gerrit.wikimedia.org/r/427533