MyBB Community Forums

Full Version: MySupport - Error Hell
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
The following warnings occurred:
Warning [2] explode() expects parameter 2 to be string, array given - Line: 2203 - File: inc/plugins/mysupport.php PHP 5.6.28 (Linux)

File
Line
Function[PHP]
 
errorHandler->error
/inc/plugins/mysupport.php
2203
explode
/inc/class_plugins.php
139
mysupport_postbit
/inc/functions_post.php
803
pluginSystem->run_hooks
/showthread.php
1066
build_postbit

Warning [2] array_merge(): Argument #2 is not an array - Line: 2203 - File: inc/plugins/mysupport.php PHP 5.6.28 (Linux)

File
Line
Function[PHP]
 
errorHandler->error
/inc/plugins/mysupport.php
2203
array_merge
/inc/class_plugins.php
139
mysupport_postbit
/inc/functions_post.php
803
pluginSystem->run_hooks
/showthread.php
1066
build_postbit

Warning [2] explode() expects parameter 2 to be string, array given - Line: 2240 - File: inc/plugins/mysupport.php PHP 5.6.28 (Linux)

File
Line
Function[PHP]
 
errorHandler->error
/inc/plugins/mysupport.php
2240
explode
/inc/class_plugins.php
139
mysupport_postbit
/inc/functions_post.php
803
pluginSystem->run_hooks
/showthread.php
1066
build_postbit

Warning [2] array_merge(): Argument #2 is not an array - Line: 2240 - File: inc/plugins/mysupport.php PHP 5.6.28 (Linux)

File
Line
Function[PHP]
 
errorHandler->error
/inc/plugins/mysupport.php
2240
array_merge
/inc/class_plugins.php
139
mysupport_postbit
/inc/functions_post.php
803
pluginSystem->run_hooks
/showthread.php
1066
build_postbit

Warning [2] explode() expects parameter 2 to be string, array given - Line: 2203 - File: inc/plugins/mysupport.php PHP 5.6.28 (Linux)

File
Line
Function[PHP]
 
errorHandler->error
/inc/plugins/mysupport.php
2203
explode
/inc/class_plugins.php
139
mysupport_postbit
/inc/functions_post.php
803
pluginSystem->run_hooks
/showthread.php
1066
build_postbit

Warning [2] array_merge(): Argument #2 is not an array - Line: 2203 - File: inc/plugins/mysupport.php PHP 5.6.28 (Linux)

File
Line
Function[PHP]
 
errorHandler->error
/inc/plugins/mysupport.php
2203
array_merge
/inc/class_plugins.php
139
mysupport_postbit
/inc/functions_post.php
803
pluginSystem->run_hooks
/showthread.php
1066
build_postbit

Warning [2] explode() expects parameter 2 to be string, array given - Line: 2240 - File: inc/plugins/mysupport.php PHP 5.6.28 (Linux)

File
Line
Function[PHP]
 
errorHandler->error
/inc/plugins/mysupport.php
2240
explode
/inc/class_plugins.php
139
mysupport_postbit
/inc/functions_post.php
803
pluginSystem->run_hooks
/showthread.php
1066
build_postbit

Warning [2] array_merge(): Argument #2 is not an array - Line: 2240 - File: inc/plugins/mysupport.php PHP 5.6.28 (Linux)

File
Line
Function[PHP]
 
errorHandler->error
/inc/plugins/mysupport.php
2240
array_merge
/inc/class_plugins.php
139
mysupport_postbit
/inc/functions_post.php
803
pluginSystem->run_hooks
/showthread.php
1066
build_postbit

Warning [2] explode() expects parameter 2 to be string, array given - Line: 2203 - File: inc/plugins/mysupport.php PHP 5.6.28 (Linux)

File
Line
Function[PHP]
 
errorHandler->error
/inc/plugins/mysupport.php
2203
explode
/inc/class_plugins.php
139
mysupport_postbit
/inc/functions_post.php
803
pluginSystem->run_hooks
/showthread.php
1066
build_postbit

Warning [2] array_merge(): Argument #2 is not an array - Line: 2203 - File: inc/plugins/mysupport.php PHP 5.6.28 (Linux)

File
Line
Function[PHP]
 
errorHandler->error
/inc/plugins/mysupport.php
2203
array_merge
/inc/class_plugins.php
139
mysupport_postbit
/inc/functions_post.php
803
pluginSystem->run_hooks
/showthread.php
1066
build_postbit

Warning [2] explode() expects parameter 2 to be string, array given - Line: 2240 - File: inc/plugins/mysupport.php PHP 5.6.28 (Linux)

File
Line
Function[PHP]
 
errorHandler->error
/inc/plugins/mysupport.php
2240
explode
/inc/class_plugins.php
139
mysupport_postbit
/inc/functions_post.php
803
pluginSystem->run_hooks
/showthread.php
1066
build_postbit

Warning [2] array_merge(): Argument #2 is not an array - Line: 2240 - File: inc/plugins/mysupport.php PHP 5.6.28 (Linux)

File
Line
Function[PHP]
 
errorHandler->error
/inc/plugins/mysupport.php
2240
array_merge
/inc/class_plugins.php
139
mysupport_postbit
/inc/functions_post.php
803
pluginSystem->run_hooks
/showthread.php
1066
build_postbit



I am running 1.8.8 everything is up to date - besides this plugin....

No idea how to fix it
Not sure if this helps at all..., but I haven't run into that error myself yet using.., https://community.mybb.com/thread-204531...pid1248119
I will have to try that, thanks!
What other plugins do you have? The value that it's saying should be a string should be a string, if it's an array on your forum it sounds like something's editing it. Do you have any plugins for multiple group images in the postbit or anything?
(2016-11-29, 01:56 PM)Matt Wrote: [ -> ]What other plugins do you have? The value that it's saying should be a string should be a string, if it's an array on your forum it sounds like something's editing it. Do you have any plugins for multiple group images in the postbit or anything?

OUGC Additional Usergroup Images (1.8)
Show additional usergroup images in profile and postbit.
Created by Omar G.


That's the only one
Yep, it's poor logic in that plugin which is the actual issue here.

${$var}['additionalgroups'] = explode(',', ${$var}['additionalgroups']);

It's exploding the string of 'additionalgroups' and turning it into array, but it's not assigning it to a new variable, it's changing the original value, which then means any plugin that runs after it (MySupport in this case), as well as even the core MyBB code, will be trying to work with an array not a string.

As a quick fix, in that plugin, line 297:

$uidscache[${$var}['uid']] = (array)${$var}['additionalgroups'];

Afterwards, add:

${$var}['additionalgroups'] = implode(',', ${$var}['additionalgroups']);

This then turns it back into a string like it should be, and should then stop the errors.
I think that did the trick, now I am getting weird issues such as images relinking to themselves

"https://www.aeythex.com/https://www.aeythex.com/images/metrostyle/mysupport_notsolved.png"

And there are no new fields in ModCP .