Wedge
Public area => Bug reports => The Pub => Archived fixes => Topic started by: Pandos on May 15th, 2014, 11:59 AM
-
Index will give a error 500 while trying to do a fresh install.
PHP Fatal error: Can't use function return value in write context in /gz/app/Subs.php on line 2
-
Reinstalled this week, had no such problem..?
-
I'm not getting quite the same error, so it should perhaps go in another thread, but I simply uploaded the newest revision files (29fdcaa) via FTP, and now I'm getting the following error, trying to view the main page:
Fatal error: Can't use function return value in write context in <redacted>/gz/app/Subs.php on line 2344
Which refers to the middle of these three lines:
// Remove the home separator if not needed.
if (empty(reset($menu_items['home']['items'])))
array_shift($menu_items['home']['items']);
I'm using the "Wireless" skin, if that's important.
-
Oh, right.
That's because I'm using PHP 5.5 both here (IIRC) and locally, and empty() doesn't support function results before that.
-
Seems to be fixed.
But there are some errors remaining in the logs:/viewremote/?filename=current-version.js
2: array_merge(): Argument #2 is not an array
Datei:/wedge/gz/app/Subs-Template.php
Zeile: 406
Also the same error for latest-news.js and search. :)
-
Okay, what's in your page_replacements setting..?
This is the thing you can fill up in the Pretty URLs admin page... But I'm more interested in the raw data in the settings table, than what the PURLs page tells you.
(It's probably an unserialize error.)
BTW, replacing lines 405 and 406 with this should work...
if (!empty($settings['page_replacements']) && ($extra_pr = unserialize($settings['page_replacements'])) !== false)
$pr = array_merge($pr, $extra_pr);
-
Your latest commit [bcd3d00] fixed this.
Great work!