Use `wp_get_attachment_url()` instead of the GUID when getting header image URLs. Fixes #27222. Props Kopepasah.
Built from https://develop.svn.wordpress.org/trunk@27434 git-svn-id: http://core.svn.wordpress.org/trunk@27281 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
c5279336c7
commit
944c629ace
|
@ -1137,7 +1137,7 @@ function get_uploaded_header_images() {
|
|||
return array();
|
||||
|
||||
foreach ( (array) $headers as $header ) {
|
||||
$url = esc_url_raw( $header->guid );
|
||||
$url = esc_url_raw( wp_get_attachment_url( $header->ID ) );
|
||||
$header_data = wp_get_attachment_metadata( $header->ID );
|
||||
$header_index = basename($url);
|
||||
$header_images[$header_index] = array();
|
||||
|
|
Loading…
Reference in New Issue