Make WordPress Core

Opened 9 years ago

Closed 8 years ago

#22986 closed defect (bug) (duplicate)

WP uses header image's GUID as URL

Reported by: bersbers Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: Customize Keywords: has-patch needs-testing
Focuses: Cc:

Description (last modified by SergeyBiryukov)

See summary. If I move my site (old domain becoming inaccessible), I cannot use my header images any more since
a) I am not allowed to change GUIDs.
b) GUIDs are used as URLs for header images:


1008        foreach ( (array) $headers as $header ) {
1009	                $url = esc_url_raw( $header->guid );

Attachments (1)

22986.patch (515 bytes) - added by toscho 9 years ago.
Use wp_get_attachment_image_src() for URL

Download all attachments as: .zip

Change History (8)

#1 @bersbers
9 years ago

I am not sure, but it seems that event newly uploaded files receive a GUID that contains the OLD domain. This means I cannot even re-upload header images, I cannot use any header image after moving a WordPress site. Can this be true?
(Probably not true generally. It does however seem true when I simply re-select the old header images from the media library. So I really need to re-upload ALL header images after moving the site?)

Last edited 9 years ago by bersbers (previous) (diff)

#2 @SergeyBiryukov
9 years ago

  • Description modified (diff)

#3 @toscho
9 years ago

  • Cc info@… added

9 years ago

Use wp_get_attachment_image_src() for URL

#4 @toscho
9 years ago

  • Keywords has-patch needs-testing added

Not sure about the size argument. Is there a registered size for header images I missed?

#5 @mikeschroder
8 years ago

  • Milestone changed from Awaiting Review to Future Release

#6 @nacin
8 years ago

  • Component changed from Themes to Appearance

#7 @SergeyBiryukov
8 years ago

  • Milestone Future Release deleted
  • Resolution set to duplicate
  • Status changed from new to closed

Duplicate of #27222.

Note: See TracTickets for help on using tickets.