12.1Issues after plugin's activation

There are minor cases in which a plugin's activation can go wrong, leaving you with a blank page either with or without error displayed.

If you are stuck with a blank screen and can't access to your WordPress dashboard anymore, don't worry: just rename the TeamBooking plugin's folder via FTP to deactivate it manually (this is a general procedure valid for any plugin). The next time you'll go into your WordPress dashboard, you will see the plugin deactivated.

Now, let's see the most common activation failure reasons, and how to fix them.

12.1.1"Unexpected T_STRING" fatal error

Hey, I've activated the plugin and now I get an Unexpected T_STRING fatal error!

This is because your server runs a PHP version 5.2 or lower, so your site will hang with an Unexpected T_STRING fatal error. Normally, the plugin won't be activated in this case. If otherwise, your site will hang.

You must switch to a more recent PHP version, which is a completely safe, one-click operation. Get in touch with your hosting to know how, or just dig into your cPanel or similar.

12.1.2"Cannot redeclare tgmpa()" fatal error

Hey, I've activated the plugin and now my site hangs! I can't access to the whole site! The error log says something like "Cannot redeclare tgmpa()", what's that?

This error is thrown because your current theme implements an outdated version of the tgmpa library, which was known to crash when other plugins make use of the same library. Recent versions of tgmpa (like the one implemented in TeamBooking) don't have this issue.

Another possibility is that your current theme indeed implements a more recent version of the library, but it is wrongly customized.

You must do the following:

  1. Ensure that you are running the very latest version of your theme. If not, update your theme to the latest version.
  2. If the issue persists, then you must report to your theme's support to upgrade their tgmpa library version, or - if customized - to check its customization looking for typos etc.
  3. If your theme's support won't be collaborative, please contact our support instead.

In the meantime, you can de-activate TeamBooking manually by renaming it's folder (wp-content/plugins/team-booking) to something else (like wp-content/plugins/team-booking2) via FTP.

12.2Some calendar fonts are too small

Some of the frontend calendar fonts and/or elements like filter buttons are too small to read, in respect to my theme.

This is often a sad result of the so-called 62.5% hack used by some themes. Try to activate the CSS fix for small fonts in the Frontend style tab.

12.3Events not showing

I've correctly setup the core settings and gave authorization in personal settings, but my availability slots in Google Calendar are not showing in the frontend caledar of my site.

Assuming that you've correctly configured the plugin as per documentation, if your availability slots are not showing up in the frontend, you must have missed something for sure. In particular, double (triple, if needed) check those things:

  • Have you correctly added one of your Google Calendars in the Personal Settings tab? You may unconsciously think that giving authorization is sufficient to fetch events, but it's not. You must add at least one of your Google Calendars.

  • Have you correctly named your availability slots in your Google Calendar? In order to be fetched and connected to a service, the event must be named exactly as indicated in Event title (free slot) in Your Google Calendar settings tab for that service (if you're using the container mode, then the word "container" must be added at the end of the event name after a single whitespace).

  • Are you respecting the When reservations should be closed? setting, inside the service's Your Google Calendar tab? Perhaps you're putting events below this time limit, so they are discarded. This mistake is more common that you may think...

    Similarly, if your When reservations should be opened? setting is other than "immediately", are you respecting this value also? Perhaps you're putting events over this time limit, so they are discarded. Also, remember that this time limit, if not set to "immediately", should be greater than the When reservations should be closed? value!

  • Have you checked your timezones? TeamBooking always uses the WordPress timezone (you can find this setting in your site's General Settings), so all the slots times are converted to that timezone. If your Google Calendar timezone (which is completely ignored) is different, you may accidentally run up against the previous step, or even worse, you may put events that are already "in the past" in respect to your WordPress timezone.

  • Are your service(s) active (Services tab)?

  • Are your participating to the service(s) (Services tab)?

  • Are you putting the availability slots in the right Google Calendar? You may have more than one Google Calendar in your Google Account. Let's assume you've only added the "My Calendar 2" in your Personal settings tab and you're putting events in your "My Calendar 1" because it's your default calendar...

12.4E-mail not sent

My customers don't receive the confirmation email, Admin/Coworker doesn't receive the notification email, or both. I'm sure the options to send those emails are activated.

Assuming that the issue is limited to emails only (i.e. the reservations are correctly recorded in your Overview tab), then the plugin is not directly responsible, as it triggers the WordPress core functions to send emails, and it uses the best practices to do so. The reason must reside elsewhere, here are a couple of suggestions:

  • Check your server's error.log file (this is a general advice for any issue). If you don't know where to retrieve it, just ask to your hosting provider.

  • Since the php mailer used by WordPress can be unreliable, you're strongly invited to install the free and powerful WP Mail SMTP plugin. It reconfigures the wp_mail() function to use SMTP instead of mail() and creates an options page to manage the settings. You can use a very reliable SMTP server like the Google one. This minimize the server-relating issues about emails.

  • Check that the admin email address you've set as sender address, actually belongs to your domain, or it can be blocked by some security policies by your server.

  • Last but not least, be sure that the email is actually not sent, rather than sent but moved to SPAM folder (in which case, once again, the problem is your server, so you'd better use the WP Mail SMTP plugin).

The confirmation and notifications e-mail messages are sent, but the reminder e-mail is not sent automatically. It is sent only when I manually trigger it. All the customers or some of them are not receiving any automatic reminder e-mail.

The reminder e-mail messages are sent via the WordPress scheduler. The WordPress scheduler triggers the actions only when your site is visited. This behaviour is unreliable, and could lead to reminders sent too late, or not sent at all, especially when your site has low visits.

Unfortunately, the only solution here is to setup a real server's cron job, for which you might visit this very good blog post. It gives you also a deeper overview of how the WordPress scheduler works.

12.5Reservations don't appear, or always pending

I'm sure some reservations were made, but I can't spot them anywhere in the Overview, neither confirmation or notification emails are sent.

Usually, this happens when you're using PayPal and there are some issue with it. In particular, when a payment is made through PayPal and it's requested immediately (in your service settings), the plugin puts the reservation in a "pending payment" status, and keep it in this "limbo" as long as the Max pending time setting in the Core settings tab says. During this time, in which essentially the plugin is waiting for the payment to be made and confirmed by PayPal, the availability slot disappears from the frontend calendar, but you can't see the reservation in the Overview tab yet.

We face two possibilities:

  1. The reservation payment status is Pending but you're sure that the payment was actually made because you've received an email from PayPal, or because you're testing the payment gateway by yourself.

    Your server is apparently not able to process the so-called PayPal IPN (instant payment notification), so the plugin can't acknowledge the correctly processed payment. What should you do?

    • Ensure that your server is SHA256 and TLSv1.2 compliant (test it), or it cannot receive the IPNs from PayPal due to security reasons.

    • If your server is compliant, then you should retrieve the error.log file of your server and inspect it (or send it to our support)

    • Next thing, activate both the IPN debug settings in the PayPal gateway settings

    • Then you should try to make a reservation while NOT logged as admin (you can use the PayPal sandbox, in order to not make real payments)

    • Wait some minutes and go back to the IPN debug section of PayPal Gateway settings, you should now be able to read the debug information (last errors and last IPN raw data).

    • Repeat the steps with both cURL and fsockopen options (PayPal gateway settings)

    • Contact our support

  2. The reservation is nowhere displayed. But it was made.

    The above steps are still valid, but you should check first of all your email inbox, as you may have received a Fraud notification email by the plugin. That means that at least one of the frauds check failed, and the details are in the email body. If you believe the failure is not legit, then please contact our support.

12.6Slots in read-only mode

The frontend calendar is OK, but customers are not able to click on the slots, when I try logged in as Admin this advice appears:

(on previous TeamBooking versions, the following error was shown instead, during the reservation attempt)

Cannot make the reservation! Sorry, you should contact the administrator providing these informations: Google API error: Error calling PATCH https://www.googleapis.com/calendar/v3/calendars/{YOURCALENDAREVENTSTRING}:(403) The operation can only be performed by the creator of the event.

If you have updated the plugin recently and this advice is now shown on all of your slots, while previously they were working fine, then please repair your database.

Otherwise, that means that the Google Calendar of the service provider (coworker) where the slot resides is shared and someone who's not the Google Calendar owner created that slot.

Please check the paragraph 13.2.3 for more details.

12.7Slots not in sync

The slots in the frontend calendars are different in number/not in sync with the events in Google Calendar.

Please try to force a full-sync of that Google Calendar in the Personal tab (check this paragraph as reference).

If you are experiencing this issue only while not logged in WordPress, then you must have some misconfigured caching plugin/system in place.