![]() |
4.2.3 Usercp Illegal string warning
Hello,
Does anybody knows what causes the follow PHP Warnings in UserCP with 4.2.3? Till 4.2.2 everything was working fine. PHP Code:
PHP Code:
|
It looks like that's in a template. It's using a string where an array is expected. I haven't seen anyone else mention that happening after upgrading to 4.2.3.
|
Quote:
A final note. All mods were working fine before upgrading. And the errors are only in usercp pages. I did a test by moving the code of one such page to a non usercp page and it works fine. |
It looks like the problem is with the variable $navclass, in case that helps.
|
Quote:
PHP Code:
|
Well, $navclass seems to be an array of CSS class names to be used for the different parts of the UserCP. It's set by calling the function construct_usercp_nav(), which is called before the USERCP template is used. But I don't see anything in the code you posted that has to do with that, and I don't know why 4.2.3 would make a difference.
|
Quote:
PHP Code:
|
$includecss is the array of css files to include. $navclass is an array of class names.
Anyway, you're calling construct_usercp_nav(), if do is 'addeditphoto', so that should be OK. Is that the entire script? If not, then look for a condition where $shell_template == 1 but you have not called construct_usercp_nav(). Otherwise, maybe a plugin is changing $navclass? Could it be the reason you don't see those messages in 4.2.2 is because error messages are turned off? |
Even if I can't test it right now seems that we're going closer to the bug:
Quote:
Quote:
Quote:
|
Quote:
When you can test, you could put in code to print out the value of $navclass at different places, and I'm sure you'll be able to figure it out. |
Quote:
--------------- Added 05 Jul 2015 at 10:35 --------------- For those who maybe have the same problem, at least in my case, I found the solution. Don't know why but the assignement to $navclass must not exists. Currently in my code, I had: PHP Code:
PHP Code:
Once again I want to thank @kh99 for the time that he spent trying to figure out the bug. Hav |
All times are GMT. The time now is 08:45 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|