This support ticket is created 6 years, 8 months ago. There's a good chance that you are reading advice that it now obsolete.
This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.
Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.
No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.
Hello, my site is running on the Siteground server. The site's search function is run by Relevanssi. However, on some searches, the site returns an Uncaught DivisionByZeroError Fatal Error and does not display any output. The complete error output is.
Fatal error: Uncaught DivisionByZeroError: Modulo by zero in /home/bstockit/public_html/OdysseyCases/wp-content/plugins/wp-views/embedded/inc/wpv-pagination-embedded.php:946 Stack trace: #0 /home/bstockit/public_html/OdysseyCases/wp-includes/shortcodes.php(319): WPV_Pagination_Embedded->wpv_pager_nav_links_callback(Array, '', 'wpv-pager-nav-l...') #1 [internal function]: do_shortcode_tag(Array) #2 /home/bstockit/public_html/OdysseyCases/wp-includes/shortcodes.php(197): preg_replace_callback('/\\[(\\[?)(wpv\\-s...', 'do_shortcode_ta...', '\n \n<div style=...') #3 /home/bstockit/public_html/OdysseyCases/wp-content/plugins/wp-views/embedded/inc/wpv-shortcodes.php(7104): do_shortcode('\n \n<div style=...') #4 /home/bstockit/public_html/OdysseyCases/wp-content/plugins/wp-views/embedded/inc/wpv-filter-embedded.php(1671): wpv_do_shortcode('\n \n<div style=...') #5 /home/bstockit/public_html/OdysseyCases/wp-includes/shortcodes.php(319): wpv_items_found('', '\n \n<div style=...', 'wpv-items-found') #6 [internal function]: do_s in /home/bstockit/public_html/OdysseyCases/wp-content/plugins/wp-views/embedded/inc/wpv-pagination-embedded.php on line 946
Hello. Thank you for contacting the Toolset support.
Well - what exactly the search term you used that is results in the error you shred in your initial post?
I see the error comes from the view's plugin pagination file but In order to minimize the cause of the issue:
Could you please try to resolve your issue by deactivating all third-party plugins as well as the default theme to check for any possible conflicts with any of the plugins or themes?
Do you see same issue with minimum setup (only Toolset plugins and default theme)? If yes:
Could you please share problem URL?
The fatal error does not occur when I am running a default wordpress theme with Toolset.
I found out Avada with PHP 7 caused the fatal error.
When I switched to Avada with PHP 5.6.34 I got php warnings instead, but the site still displays the correct output.
Warning: Division by zero in /wp-content/plugins/wp-views/embedded/inc/wpv-pagination-embedded.php on line 946
Now, is it Avada's incompatibility with PHP 7 that caused the error or compatibility between Avada and Toolset?
Obviously, something happened in the coding that caused a division by zero in wpv-pagination-embedded.php which in 5.6.34 is a warning and in 7.0 is a fatal error.
I've removed the full path that might be the problem why you asked to make last replay private.
Well - if it works with default theme that means there is some issue with PHP version and Avada.
Could you please check with them and first confirm that issue is from Toolset or its from Avada. If the issue is from Toolset - we are happy to debug this further.