Skip to content

Conversation

@micgro42
Copy link
Contributor

@micgro42 micgro42 commented Jan 1, 2021

In the big refactoring of html.php in Dokuwiki, the events like HTML_EDITFORM_OUTPUT were removed and replaced with FORM_EDIT_OUTPUT. See dokuwiki/dokuwiki#3198

This PR adds support for the new event and maintains the support for the legacy one. It is expected to work both on the currently released version of DokuWiki and the current tip of the development branch.

This is broken since mid-October. I'm surprised nobody has complained so far?

Copy link
Contributor

@annda annda left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent, thank you for the fix. Just please adjust the two lines addressed by comments.

action/edit.php Outdated
*
* Handles the FORM_EDIT_OUTPUT event
*/
public function addFromData(Doku_Event $event, $_param): bool
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This declaration should be changed to retain compatibility with PHP 5.6, still officially supported by DokuWiki.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hogfather still supports PHP 5.6? 🧐

Fixed.

action/edit.php Outdated
return true;
}

private function getEditorHtml(): string
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PHP 5.6 incompatible declaration

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed.

In the big refactoring of html.php in Dokuwiki, the events like
HTML_EDITFORM_OUTPUT were removed and replaced with FORM_EDIT_OUTPUT.
See dokuwiki/dokuwiki#3198

This PR adds support for the new event and maintains the support for the
legacy one. It is expected to work both on the currently released
version of DokuWiki and the current tip of the development branch.
@annda annda merged commit 09ea1bf into cosmocode:master Jan 3, 2021
@micgro42 micgro42 deleted the fixMissingStructEditor branch April 15, 2021 13:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants