Skip to content
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

PHP7.1 "non-numeric value encountered" warning from /core/menu/megamenu.php #74

Open
jimmisonr opened this issue Oct 15, 2018 · 2 comments

Comments

@jimmisonr
Copy link

The code on line 337 of /core/menu/megamenu.php needs to be changed from
$width += $colw; to $width = $colw; (remove the +).

This code is part of a if-statement that first of all tests for !$width. The error is thrown because in PHP7.1, it seems that you can no longer do mathematical operations (addition, in this case via the +=) on a null variable. The + should not have been used in the code at all because the if-statement already has established that $width is undefined or 0.

@jimmisonr
Copy link
Author

... or for another solution (which I think addresses the core problem better): see sqopnil's Pull Request at https://github.com/themexpert/Expose-Framework-Library/pull/73/files

@mazharvai007
Copy link
Contributor

Thank you for finding out the issue. The issue is fixed. Please upgrade the Expose framework.

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

No branches or pull requests

2 participants