On our event pages, right above where the details and ticket quantity is located, I’m displaying the following error code:
Warning: count(): Parameter must be an array or an object that implements Countable in /home/customer/www/toalltech.com/public_html/wp-includes/post-template.php on line 319
EE is updated and WP is updated to latest version.
I can’t reproduce this on my tests sites and the error is from a WP core file so it’s likely either the theme (or another plugin) is doing something unexpected here.
First, create a database backup before moving forward (just to be safe).
As you don’t have a development copy, one way to confirm if this is the case is to use the WP Health Check & Troubleshooting plugin:
Install and activate it on the site, then go to Tools -> Health Check -> Troubleshooting. Enable Troubleshooting mode.
That will deactivate all plugins and switch you to a default theme, but only for you (the logged in admin).
In the admin bar go to troubleshooting mode and Manage Active Plugins.
Enable Event Espresso.
Now view the event page, does it show an error there? (It shouldn’t)
Then, try switching to your theme (In troubleshooting mode on the admin bar again Themes -> select your theme)
Test again, does it show the error?
If yes, then its something within your theme causing it.
If not, enable each of the plugins you use on your site (again from troubleshooting mode) and test between activating each one until it shows the error. Then let me know which plugin.
—
To deactivate Troubleshooting mode go to the Admin Bar -> TroubleShooting Mode -> Disable Troubleshooting Mode.
Viewing 3 reply threads
The support post ‘Error code when viewing event page before registration.’ is closed to new replies.
Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.
Support forum for Event Espresso 3 and Event Espresso 4.