0

Hello I get the following error on the products pages with PHP 7.2 , Magento 2.33

Exception #0 (Exception): Warning: count(): Parameter must be an array or an object that implements Countable in /chroot/home/ae393a83/xxxxxxxx.com/app/code/Smartwave/Porto/Helper/Customtabs.php on line 74

Thanks Martin

2
  • you should update / patch your Porto theme to the latest version that supports M2.3.3
    – paj
    Commented May 23, 2020 at 18:19
  • Sorry - the latest had the bug in it @paj Commented May 24, 2020 at 6:02

2 Answers 2

2

Try this Way..:

if ( count( $cms_tabs )) {
....
}

Add "is_array($cms_tabs) &&" to become:

if (is_array($cms_tabs) && count($cms_tabs) ) {
....
}
0
0

I find a solution.

Go to Stores -> Configuration -> Porto -> Porto - Settings Panel -> Product View -> Product Custom Tabs.

In that section I add and delete for Product Custom Static Block Tabs and Product Custom Attribute Tabs. I leave them with 0 rows and saved. Cleared the cache and now works.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.