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

PHP Warning: Parameter 1 to PlgSystemLogout::handleError() expected to be a reference, value given in /libraries/legacy/error/error.php on line 780 #18476

Closed
infograf768 opened this issue Nov 2, 2017 · 19 comments

Comments

@infograf768
Copy link
Member

infograf768 commented Nov 2, 2017

Steps to reproduce the issue

Log in frontend ( I did as superadmin).
Login form module is set to display on all pages.
Edit an article.
Logout through the module

You get that Warning. Logout is done OK

Note: test done on a clean staging multilingual site

@ghost
Copy link

ghost commented Nov 2, 2017

Can't confirm. Logout by Module (display on all Pages) give:
bildschirmfoto 2017-11-02 um 10 47 30

@infograf768
Copy link
Member Author

You get that, but the Warning shows in the PHP error logs, not on the page.

@ghost
Copy link

ghost commented Nov 2, 2017

Had looked before Comment in php_error.log, didn't get it there too.

@infograf768
Copy link
Member Author

weird

@Quy
Copy link
Contributor

Quy commented Dec 19, 2017

@infograf768 I can reproduce the warning in the error log.

@infograf768
Copy link
Member Author

@Quy @franz-wohlkoenig
I see that Franz did his test while using a test sample data while I just had used the default multilang setting when installing J.
Quy, what your were your settings?

@Quy
Copy link
Contributor

Quy commented Dec 20, 2017

Installed Test English (GB) Sample Data demo.
Edit an article in the front end.
Click the Log out button.
View error log.

@infograf768
Copy link
Member Author

Thanks for info.

@ghost
Copy link

ghost commented Dec 20, 2017

Test again on clean Install: No Warning in php_error.log.

System information

3.8.4-dev
Multilanguage Site (4 Lang.) & Test English (GB) Sample Data
macOS Sierra, 10.12.6
Firefox 57 (64-bit)

MAMP 4.2

  • PHP 7.0.22
  • MySQLi 5.6.35

@infograf768
Copy link
Member Author

@franz-wohlkoenig
Have you tested when the article is in the edit state, i.e. not saved yet?

@ghost
Copy link

ghost commented Dec 20, 2017

2 Versions:

  • Open Article, change something, click on Log-out-Button of Module (there comes PopUp "Do you really wanna leave Page")
  • Open Article and click on Log-out-Button of Module

In both Cases no Warning.

@infograf768
Copy link
Member Author

I think I found why we have that.
the method is
public static function handleError(&$error) in /plugins/system/logout/logout.php
If I change to public static function handleError($error)
No more Warning
It may be related to the PHP version as using the reference is there for compatibility with php 5.3
What is weird is that @franz-wohlkoenig does not get the issue although he uses a 7.x php version.
Maybe it is related to his 7.0.22 bersion?
My version of PHP is 7.1.8

@infograf768
Copy link
Member Author

I confirm: using php 7.0.22 does NOT throw the warning

@ghost
Copy link

ghost commented Dec 20, 2017

@infograf768 confirm: got Error after changing PHP-Version to 7.1.8 in Mamp.

@infograf768
Copy link
Member Author

@Quy
What is your PHP version?

@Quy
Copy link
Contributor

Quy commented Dec 20, 2017

PHP 7.1.11 & PHP 7.2.0

@Quy
Copy link
Contributor

Quy commented Dec 29, 2017

Maybe this will give some insights: https://forum.joomla.org/viewtopic.php?t=930067

@joomla-cms-bot
Copy link

Set to "closed" on behalf of @franz-wohlkoenig by The JTracker Application at issues.joomla.org/joomla-cms/18476

@ghost
Copy link

ghost commented Dec 30, 2017

closed as having Pull Request #19233

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants