[wp-trac] [WordPress Trac] #31866: wp_redirect strips out special characters

WordPress Trac noreply at wordpress.org
Thu Apr 2 08:20:41 UTC 2015


#31866: wp_redirect strips out special characters
--------------------------+-----------------------------
 Reporter:  Milmor        |      Owner:
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  General       |    Version:  4.1.1
 Severity:  normal        |   Keywords:
  Focuses:                |
--------------------------+-----------------------------
 Forum post:
 [https://wordpress.org/support/topic/wp_redirect-strips-out-special-
 characters?replies=1]

 i have a problem with the function wp_redirect() when the url contains
 special characters.

 wp_redirect( esc_url_raw( wp_get_attachment_url( $ID ) ) );

 If the attachment url contains, for example, '''À''', then the entire line
 of code leads to a 404 page because the final url won't contain that
 letter.

 In addition:
 esc_url_raw( wp_get_attachment_url( $ID ) )
 is returning the correct url. Without esc_url_raw i get the same result.

 It seems that wp_redirect strips out the character À. Is this normal?

 (Apache server)

--
Ticket URL: <https://core.trac.wordpress.org/ticket/31866>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list