[wp-trac] [WordPress Trac] #61352: PHP deprecation notice in wp_title() (was: PHP deprecation warning in /wp-includes/general-template.php)

WordPress Trac noreply at wordpress.org
Fri Apr 25 20:58:32 UTC 2025


#61352: PHP deprecation notice in wp_title()
--------------------------+---------------------
 Reporter:  nexbridge     |       Owner:  (none)
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  6.9
Component:  Themes        |     Version:  6.5.5
 Severity:  normal        |  Resolution:
 Keywords:  has-patch     |     Focuses:
--------------------------+---------------------

Comment (by sabernhardt):

 My alternative suggestion, whether it includes `empty()` or `null ===
 $title`, would only be a good idea if some situation //should// give an
 error (that is, if it ever indicates doing something wrong). I did not
 create a patch because I am not convinced my direction is better than PR
 8729.

 If this function's deprecation notice should be silenced in **all** cases,
 `wp_resolve_block_style_variation_ref_values()` already established a
 precedent with
 `explode( '.', $value['ref'] ?? '' )` and comment:2 says that syntax is
 compatible with PHP 7.0.

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


More information about the wp-trac mailing list