Wedframe
04-28-2014, 02:19 PM
Hi. Please help me with modification of plugin. This plugin work perfectly on the default style, but on installed custom style his generate php-errores:
Object of class vB_Template could not be converted to string....
strpos() expects parameter 1 to be string, object given...
Ofcause after this the page not loading....
I found hook and localized code what gives this errores. Its in parse_template
if ($vbulletin->options['legacypostbit'] AND isset($vbulletin->templatecache['postbit_legacy']) AND is_member_of($vbulletin->userinfo, unserialize($vbulletin->options['mkp_self_moderation_group'])))
{
$template =& $vbulletin->templatecache['postbit_legacy'];
}
If I comment action of statement "if"
if ($vbulletin->options['legacypostbit'] AND isset($vbulletin->templatecache['postbit_legacy']) AND is_member_of($vbulletin->userinfo, unserialize($vbulletin->options['mkp_self_moderation_group'])))
{
//$template =& $vbulletin->templatecache['postbit_legacy'];
}
then page load without errores, but plugin not work correctly.
Thanks for any help!
Object of class vB_Template could not be converted to string....
strpos() expects parameter 1 to be string, object given...
Ofcause after this the page not loading....
I found hook and localized code what gives this errores. Its in parse_template
if ($vbulletin->options['legacypostbit'] AND isset($vbulletin->templatecache['postbit_legacy']) AND is_member_of($vbulletin->userinfo, unserialize($vbulletin->options['mkp_self_moderation_group'])))
{
$template =& $vbulletin->templatecache['postbit_legacy'];
}
If I comment action of statement "if"
if ($vbulletin->options['legacypostbit'] AND isset($vbulletin->templatecache['postbit_legacy']) AND is_member_of($vbulletin->userinfo, unserialize($vbulletin->options['mkp_self_moderation_group'])))
{
//$template =& $vbulletin->templatecache['postbit_legacy'];
}
then page load without errores, but plugin not work correctly.
Thanks for any help!