MyBB Community Forums
MySupport - Error Hell - Printable Version

+- MyBB Community Forums (https://community.mybb.com)
+-- Forum: Extensions (https://community.mybb.com/forum-201.html)
+--- Forum: Plugins (https://community.mybb.com/forum-73.html)
+---- Forum: Plugin Support (https://community.mybb.com/forum-72.html)
+---- Thread: MySupport - Error Hell (/thread-206144.html)



MySupport - Error Hell - Zaqre - 2016-11-25

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


RE: MySupport - Error Hell - User 6029 - 2016-11-27

Not sure if this helps at all..., but I haven't run into that error myself yet using.., https://community.mybb.com/thread-204531-post-1248119.html#pid1248119


RE: MySupport - Error Hell - Zaqre - 2016-11-27

I will have to try that, thanks!


RE: MySupport - Error Hell - Matt - 2016-11-29

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?


RE: MySupport - Error Hell - Zaqre - 2016-11-29

(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


RE: MySupport - Error Hell - Matt - 2016-11-29

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.


RE: MySupport - Error Hell - Zaqre - 2016-11-29

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 .