Skip Navigation

[Resuelto] Fatal error Unknown format specifier "S" with Types and PHP8

This support ticket is created hace 1 año, 10 meses. 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.

Hoy no hay técnicos de soporte disponibles en el foro Juego de herramientas. Siéntase libre de enviar sus tiques y les daremos trámite tan pronto como estemos disponibles en línea. Gracias por su comprensión.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Kolkata (GMT+05:30)

Este tema contiene 5 respuestas, tiene 2 mensajes.

Última actualización por stefanoT-2 hace 1 año, 9 meses.

Asistido por: Minesh.

Autor
Mensajes
#2544993

I have a development website with Types, the Twenty Twenty-One theme and nothing else, just some deactivated plugins and themes.

If I try to enable PHP 8 or more, I get a fatal error in my server log. With PHP 7.4 everything works.

I found your post about the compatibility with PHP 8 so I'm confused on why it does not work for me, without any other plugin or custom themes.

What can I do?

This is the full error:

AH01071: Got error 'PHP message: PHP Fatal error: Uncaught ValueError: Unknown format specifier "S" in /var/www/vhosts/sviluppore.domyno.marketing/httpdocs/wp-content/plugins/types/vendor/toolset/types/embedded/includes/custom-taxonomies.php:199
Stack trace:
#0 /var/www/vhosts/sviluppore.domyno.marketing/httpdocs/wp-content/plugins/types/vendor/toolset/types/embedded/includes/custom-taxonomies.php(199): sprintf()
#1 /var/www/vhosts/sviluppore.domyno.marketing/httpdocs/wp-content/plugins/types/vendor/toolset/types/embedded/includes/custom-taxonomies.php(68): wpcf_custom_taxonomies_register()
#2 /var/www/vhosts/sviluppore.domyno.marketing/httpdocs/wp-content/plugins/types/vendor/toolset/types/embedded/functions.php(109): wpcf_custom_taxonomies_init()
#3 /var/www/vhosts/sviluppore.domyno.marketing/httpdocs/wp-includes/class-wp-hook.php(308): wpcf_init_custom_types_taxonomies()
#4 /var/www/vhosts/sviluppore.domyno.marketing/httpdocs/wp-includes/class-wp-hook.php(332): WP_Hook->apply_filters()\n#5 /var/www/vhosts/sviluppore.domyn...', referer: <em><u>enlace oculto</u></em>

Edit: improved code formatting.

#2545279

Minesh
Supporter

Idiomas: Inglés (English )

Zona horaria: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

As you can see with our requirement Doc:
=> https://toolset.com/toolset-requirements/

PHP 8.1 is currently not supported due to some issues. We’re working on fixing this. In the meantime, please use PHP 8.0 version.

Can you please try to update to PHP 8.0.x?

#2545423

The problem occurs even with PHP 8.0.27

#2545505

Minesh
Supporter

Idiomas: Inglés (English )

Zona horaria: Asia/Kolkata (GMT+05:30)

Can you please tell me with what taxonomy you have issue with?

Can I have problem URL and admin access details?

*** Please make a FULL BACKUP of your database and website.***
I would also eventually need to request temporary access (WP-Admin and FTP) to your site. Preferably to a test site where the problem has been replicated if possible in order to be of better help and check if some configurations might need to be changed.

I would additionally need your permission to de- and re-activate Plugins and the Theme, and to change configurations on the site. This is also a reason the backup is really important. If you agree to this, please use the form fields I have enabled below to provide temporary access details (wp-admin and FTP).

I have set the next reply to private which means only you and I have access to it.

#2546409

Minesh
Supporter

Idiomas: Inglés (English )

Zona horaria: Asia/Kolkata (GMT+05:30)

I checked with my local server where I installed the same PHP version 8.0.27 and then I installed the Toolset Types latest version and for me it was working fine.

Can you please check now.

There is a custom taxonomy SEO and the label for "new_item_name" that taxonomy was the issue as you can seeit shows label "Nuovo %S":

"new_item_name";s:8:"Nuovo %S";s:26:"separate_items_with_commas";s:0:"";s:19:

I've changed the %S to %s.

I can see now its working. Can you please confirm it works at your end as well.

#2546507

Thank you very much Minesh, I confirm everything works on my end too!