WordPress 4.5.4 wp-login bug with php7

Fatal error: Uncaught Error: Cannot create references to/from string offsets in /Users/USERNAME/Documents/Websites/PROJECTNAME/web/wp/wp-includes/user.php:56 Stack trace: #0 /Users/USERNAME/Documents/Websites/PROJECTNAME/web/wp/wp-login.php(784): wp_signon('', '') #1 {main} thrown in /Users/USERNAME/Documents/Websites/PROJECTNAME/web/wp/wp-includes/user.php on line 56

actually it was fixed in 4.7.

https://github.com/WordPress/WordPress/blob/4.7/wp-login.php#L787

Fix: Line 787 in wp-login.php change as follows:

$user = wp_signon(  ” , $secure_cookie );

to the following:

$user = wp_signon( array(), $secure_cookie );

 

World Press version info can be obtained directly from:

/wp-includes/version.php

see also https://github.com/roots/bedrock/issues/289

 

Source: WordPress/WordPress

Leave a Reply

Skip to toolbar