Skip Navigation

[Resuelto] Please re-open /topic/php-deprecated-notices-with-wp-5.5/

This support ticket is created hace 4 años, 3 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
- 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 -
- 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 -

Supporter timezone: Europe/London (GMT+00:00)

Este tema contiene 5 respuestas, tiene 2 mensajes.

Última actualización por julieP hace 4 años, 3 meses.

Asistido por: Nigel.

Autor
Mensajes
#1745199

Sorry was unable to get back to you before the robot closed this ticket.

When I originally upgraded to WordPress 5.5, I checked my site health notices and, as advised, upgraded to PHP 7.4. After your response to my original ticket, I rolled back WordPress (but not PHP) and I haven't had the original errors since. However, I have seen this deprecated notice a couple of times:-

PHP Deprecated:  array_key_exists(): Using array_key_exists() on objects is deprecated. Use isset() or property_exists() instead in /home/XXXXXX/public_html/wp-content/plugins/types/vendor/toolset/types/embedded/classes/class.wpcf-post-types.php on line 471

The array_key_exists function isn't deprecated. Is this error notice being thrown by Toolset or WordPress? Is Toolset compatible with PHP 7.4?

#1745369

Nigel
Supporter

Idiomas: Inglés (English ) Español (Español )

Zona horaria: Europe/London (GMT+00:00)

Hi Julie

This is just a deprecation notice, so it shouldn't affect functionality now (though it could in the future).

I've just updated my test server to use PHP 7.4 and I'm not seeing that message in the logs.

Do you know what you do to provoke it?

#1748105

Hi Nigel

My point is that the function ISN'T deprecated and I've seen other users reporting odd notices when using PHP 7.4 which is why I'm asking if Toolset is throwing the error or WordPress and whether Toolset is compatible with PHP 7.4.

I believe this particular notice appeared when I created new Post Type. Does that help?

#1748185

Nigel
Supporter

Idiomas: Inglés (English ) Español (Español )

Zona horaria: Europe/London (GMT+00:00)

No, the function isn't deprecated, but its use on objects is deprecated, that's what the error message produced by PHP describes.

I wasn't able to reproduce the notice, but studying the code in question it is easy enough to see why it is triggered (array_key_exists is called on an object rather than an array), and I've shared that with the developers so that it can be changed.

As I stated in my first reply, it is a deprecation notice, so doesn't currently have any effect on functionality, and doesn't mean Toolset is incompatible.

These kind of notices are fixed as and when they are discovered, either from user reports or from our internal testing.

#1753323

I've shared that with the developers so that it can be changed
thank you - this is what I was looking for you to tell me initially

#1753325

My issue is resolved now. Thank you!