This error might appear on websites using PHP7 and there are two possible solutions depending on your Template:
XTC3 Templates
These templates are built using our own XTC framework. You can tell if your template is one of these by checking the presence of an "XTC" folder inside the template directory.
The easiest way to update them is to just download the latest template version and installing it like any other extension. If you have customized the code, then follow the manual process described below. As a reminder, if you want to alter the CSS code in an XTC template then place all your CSS overrides in a file called "template.css" and store it in the template's css folder. This way you can safely update the template at any time without loosing your changes.
Manual process
- Locate the following file on your template folder: "XTC/XTC_library.php".
- Edit the file and go around line 620 where you should see the following lines:
case 'message'; $total += strlen($doc->getBuffer($type,$name,'')) > 0 ? 1 : 0; break; default: // modules $total += ($doc->getBuffer($type,$name,'') === false) ? 0 : count(JModuleHelper::getModules($name)); break;
- Change the lines to look like this:
case 'message'; $total += strlen($doc->getBuffer($type,$name,array())) > 0 ? 1 : 0; break; default: // modules $total += ($doc->getBuffer($type,$name,array()) === false) ? 0 : count(JModuleHelper::getModules($name)); break;
- Save your changes and place the file back to your website. The error will not appear anymore.
XTC4 Templates
Templates using XTC4 offer an improved GUI and configurable plugin effects, and they require XTC4 Helper Component to be installed.
For the problem related to this article the update procedure for them is slightly different: Instead of reinstalling the template, you just reinstall the XTC4 Helper Component. There is no need to edit any template files although the same tip for "template.css" still applies, in case you need such customization.