[wp-trac] [WordPress Trac] #16859: esc_url eats square brackets.
WordPress Trac
noreply at wordpress.org
Sun Jul 20 02:46:26 UTC 2014
#16859: esc_url eats square brackets.
------------------------------------+-----------------------------
Reporter: f00f | Owner: westi
Type: defect (bug) | Status: accepted
Priority: normal | Milestone: Future Release
Component: Formatting | Version: 3.1
Severity: major | Resolution:
Keywords: has-patch dev-feedback | Focuses:
------------------------------------+-----------------------------
Comment (by mordauk):
Looks like `wp_sanitize_redirect()` also eats square brackets:
https://core.trac.wordpress.org/browser/tags/3.9.1/src/wp-
includes/pluggable.php#L1135
Input:
`wp_sanitize_redirect( 'http://localhost/wordpress/wp-
admin/admin.php?var[]=test&var[]=test2' )`:
Expected output:
`http://localhost/wordpress/wp-admin/admin.php?var[]=test&var[]=test2`
Actual output:
`http://localhost/wordpress/wp-admin/admin.php?var=test&var=test2`
--
Ticket URL: <https://core.trac.wordpress.org/ticket/16859#comment:30>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list