• Resolved playdiune

    (@playdiune)


    Hello,

    when someone tryes to send a reservation, the site goes to an infinite loop. This is happening since a started to translate the site with translatepress.

    I checked the error and there is a conflit with translatepress (when sending the confirmation emails to admin and to the client.

    PHP Fatal error: Uncaught ArgumentCountError: Too few arguments to function trp_strip_gettext_from_get_the_date(), 1 passed in /home/gestaodigusto/public_html/wp-includes/class-wp-hook.php on line 287 and exactly 3 expected in /home/gestaodigusto/public_html/wp-content/plugins/translatepress-multilingual/includes/compatibility-functions.php:564
    Stack trace:

    #0 /home/gestaodigusto/public_html/wp-includes/class-wp-hook.php(287): trp_strip_gettext_from_get_the_date(‘2020-05-15 14:0…’)

    #1 /home/gestaodigusto/public_html/wp-includes/plugin.php(206): WP_Hook->apply_filters(‘2020-05-15 14:0…’, Array)

    #2 /home/gestaodigusto/public_html/wp-content/plugins/restaurant-reservations/includes/Booking.class.php(134): apply_filters(‘get_the_date’, ‘2020-05-15 14:0…’)

    #3 /home/gestaodigusto/public_html/wp-content/plugins/restaurant-reservations/includes/Notification.Email.class.php(251): rtbBooking->format_date(‘2020-05-15 14:0…’)

    #4 /home/gestaodigusto/public_html/wp-content/plugins/restaurant-reservations/includes/Notification.Email in /home/gestaodigusto/public_html/wp-content/plugins/translatepress-multilingual/includes/compatibility-functions.php on line 564

    Is there something i can do to solve this ?

    Thanks

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support jaysupport

    (@jaysupport)

    Hi play,

    While I can’t troubleshoot the errors referencing files in the other plugin, judging by the errors/lines mentioned from our plugin, it looks like the date format is being messed up by the translation tool.

    Do you notice any difference between the way the date looks in your booking forms across different languages?

    What happens if you temporarily (just as a test) disable the translatepress plugin, does the date format of bookings in the admin change? This is just to see if the plugin is indeed changing it.

    Also, what happens if you enter a value in the “Date Format” and “Time Format” fields in the Basic area of the Settings page? Do those override what’s being automatically set by the translate plugin and subsequently allow the booking process to start working again?

    You could also try using the redirect pages instead of the success messages for when a booking is made. Perhaps they might offer a different outcome concerning the looping.

    Thread Starter playdiune

    (@playdiune)

    Hello,
    Thanks for the response.

    The problem was solved with a translatepress plugin update. It seems the problem is your plugin has apply_filters(‘get_the_date’, $date) without the extra parameters.

    But now, its all ok.

    Thanks

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Fatal error sending confirmation emails’ is closed to new replies.