-
-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Example in manual was not working... (issue with script function name) #1
Comments
2 tasks
|
TimWolla
referenced
this issue
in WoltLab/laminas-progressbar
Jul 28, 2022
The `$text` parameter is documented to take a `string`, not a `?string` and in fact the Console adapter unconditionally calls a variant of `substr()` on the given `$text` to shorten it to the configured display width. With PHP 8.1 this fails, because native functions no longer accept `null` for a string parameter: > TypeError: grapheme_substr(): Argument #1 ($string) must be of type string, null given in […] Signed-off-by: Tim Düsterhus <[email protected]>
TimWolla
referenced
this issue
in WoltLab/laminas-progressbar
Jul 28, 2022
The `$text` parameter is documented to take a `string`, not a `?string` and in fact the Console adapter unconditionally calls a variant of `substr()` on the given `$text` to shorten it to the configured display width. With PHP 8.1 this fails, because native functions no longer accept `null` for a string parameter: > TypeError: grapheme_substr(): Argument #1 ($string) must be of type string, null given in […] Signed-off-by: Tim Düsterhus <[email protected]>
TimWolla
referenced
this issue
in WoltLab/laminas-progressbar
Jul 28, 2022
The `$text` parameter is documented to take a `string`, not a `?string` and in fact the Console adapter unconditionally calls a variant of `substr()` on the given `$text` to shorten it to the configured display width. With PHP 8.1 this fails, because native functions no longer accept `null` for a string parameter: > TypeError: grapheme_substr(): Argument #1 ($string) must be of type string, null given in […] Signed-off-by: Tim Düsterhus <[email protected]> (cherry picked from commit 965a447)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Provide a narrative description of what you are trying to accomplish.
I just wanted to play around with the examples to realize a progressbar with a JsPush-adapter.
Code to reproduce the issue
See the examples in the documentation and my question in stackoverflow, too:
https://stackoverflow.com/questions/50396543/zend-framework-3-how-to-use-and-push-update-progressbar
Expected results
The update-function should have been called and the progressbar should have been updated.....
Actual results
Nothing happened.
After renaming the update function to "ZendProgressBarUpdate" and adding the line
$this->adapter->setUpdateMethodName("ZendProgressBarUpdate");
everything worked as expected.
So I suggest to update the manual.
Originally posted by @kolbius at zendframework/zend-progressbar#26
The text was updated successfully, but these errors were encountered: