[wp-trac] [WordPress Trac] #63066: Warning when array passed to wp_check_invalid_utf8()
WordPress Trac
noreply at wordpress.org
Thu Mar 6 15:57:33 UTC 2025
#63066: Warning when array passed to wp_check_invalid_utf8()
--------------------------+-----------------------------
Reporter: leedxw | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version: 6.7.2
Severity: normal | Keywords:
Focuses: |
--------------------------+-----------------------------
{{{wp_check_invalid_utf8()}}} specifies
{{{
* @param string $text The text which is to be checked.
}}}
and will trigger the following warning if passed an array.
{{{
PHP Warning: Array to string conversion in /var/www/html/wp-
includes/formatting.php on line 1096
}}}
To reproduce
{{{
curl -v "http://localhost/wp-login.php?redirect_to[]=http://"
}}}
I would suggest returning an empty string if presented with an array.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/63066>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list