[wp-trac] [WordPress Trac] #58772: PHP 8.1 - PHP Deprecated: strpos(): /wp-includes/functions.php on line 7053 PHP Deprecated: str_replace(): /wp-includes/functions.php on line 2165

WordPress Trac noreply at wordpress.org
Tue Aug 8 19:22:20 UTC 2023


#58772: PHP 8.1 - PHP Deprecated: strpos(): /wp-includes/functions.php on line 7053
PHP Deprecated: str_replace(): /wp-includes/functions.php on line 2165
-------------------------+-----------------------------------------------
 Reporter:  collieit     |       Owner:  (none)
     Type:  enhancement  |      Status:  closed
 Priority:  normal       |   Milestone:
Component:  General      |     Version:  6.2.2
 Severity:  normal       |  Resolution:  invalid
 Keywords:  php81 close  |     Focuses:  administration, coding-standards
-------------------------+-----------------------------------------------
Changes (by hellofromTonya):

 * status:  new => closed
 * resolution:   => invalid
 * milestone:  Awaiting Review =>


Comment:

 Hello @collieit,

 Welcome to Core's Trac!

 I agree with @jrf that the issue needs to fixed in the theme or plugin(s)
 that are causing it. #58728 identified Blog2Social is one of the plugins
 that has the incompatibility. Please reach out to the plugin authors to
 report the issue.

 Also noting, there will be an architectural discussion for input
 (parameter / property) validation across all of Core's source code. As
 strict types and type declarations are likely not possible in Core, a Core
 specific structured approach is needed for handling situations as you've
 noted where for example a `string` is expected and required, but a `null`
 is given.

 For now, the native PHP notices are alerting to the issue, albeit it takes
 more digging to find the root cause.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/58772#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list