Emit a guard newline in TextareaElement to preserve leading newlinesA browser's HTML parser ignores a single newline immediately after a<textarea> start tag, so a value whose first character is a
Emit a guard newline in TextareaElement to preserve leading newlinesA browser's HTML parser ignores a single newline immediately after a<textarea> start tag, so a value whose first character is a newline lostit on round-trip (e.g. saving a page or section whose source starts witha blank line silently dropped that line).Emit a guard newline right after the start tag so the one the browserdrops is absorbed and the value stays intact.
show more ...
updated rector and applied it
code style: line breaks
code style: operator spacing
coding style: control flow whitespaces
codestyle adjustments: function declaration braces/spaces
codestyle adjustments: class declaration braces
Apply rector fixes to inc/Form
Prevent double escaping of form labels\dokuwiki\Form\Form::addLabelHTML() should not escape label content (again)
Support the multiple attribute in Form selectsThis should fix a problem mentioned inhttps://github.com/splitbrain/dokuwiki-plugin-data/pull/229#issuecomment-1196367602Note that prefilling from $
Support the multiple attribute in Form selectsThis should fix a problem mentioned inhttps://github.com/splitbrain/dokuwiki-plugin-data/pull/229#issuecomment-1196367602Note that prefilling from $INPUT is still only supported for singlevalue selects.
Fix undefined array keys when displaying revisions
change event naming schemeFORM_*_OUTPUT scheme had been introduced since Apriil 2018, see #2286
fix missing or unnecessary use Event statements
Form::toHTML() can trigger eventNew event naming scheme HTMLFORM_*_OUTPUT should be tiggered to prevent break of old third-party plugins using old events HTML_*FORM_OUTPUT.
show checkbox and radio before its label text
PSR-12 coding style
Fix curly brace syntax. PHP 7.3 deprecations in inc/ directory.
visibility fixesFirst start at declaring visibilites for methods and properties. Stillmissing: the parser/renderer stuff and the plugins
line lengths shortenedThis makes sure all files use line lenghts shorter than 120 characters.This is a quick fix. It might not always be the nicest change.
Fix buttons with invalid empty name attributesThe search buttons from the search form on the top of the pageas well as the search page both produce invalid HTMLdue to the name attribute being emp
Fix buttons with invalid empty name attributesThe search buttons from the search form on the top of the pageas well as the search page both produce invalid HTMLdue to the name attribute being empty.As the name is required for each of the PHP functionsproducing the buttons and is passed as an empty string,this makes sure that parameters with empty strings get skipped.
feat(Form): add parameter to omit security token in formsThis is useful for anonymously useable forms, like the search.
feat(Form): add method to get position of element by element
fix: prevent two selected options, b/c apparently 'String' == 0 There was a bug, where the options array ['Auto', 0, 1] would result inHTML option tags where both the 'Auto' and the 0 option we
fix: prevent two selected options, b/c apparently 'String' == 0 There was a bug, where the options array ['Auto', 0, 1] would result inHTML option tags where both the 'Auto' and the 0 option were selected.
Throw an exception if an attribute array including the attribute 'selected' is givento 'OptGroup::options()' as this would lead to an <option> tag having two 'selected' attributes.
Fix strict warnings in optgroups/dropdownsPHP 5.6 and below throw a strict standards warning at the changed lines.An intermediate variable is introduced to avoid this warning.PHP 7+ changes the
Fix strict warnings in optgroups/dropdownsPHP 5.6 and below throw a strict standards warning at the changed lines.An intermediate variable is introduced to avoid this warning.PHP 7+ changes the severity of this warning to E_NOTICE which issuppressed by DokuWiki.This error was introduced in #1778
123