Make WordPress Core

Opened 9 years ago

Last modified 5 years ago

#30887 new defect (bug)

Imported media relies on GUID for download

Reported by: pathartl's profile pathartl Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: Import Keywords:
Focuses: Cc:


When importing media with the importer plugin, the GUID is used as the URL for downloading the files. If there is more than two levels of sites you're importing between this creates an issue with flow.

In example, say you have three sites: (Original WP install)

Exporting from and importing on the files will be downloaded from

However, if you export from and import into, without changing the GUID, the files will be downloaded from

In most cases would be nonexistent or unreachable at this point, thus the media items cannot be imported.

Note that wp_get_attachment_url had this same defect (7622)

Change History (3)

#1 @DrewAPicture
9 years ago

  • Keywords close added
  • Version trunk deleted

This seems like expected behavior to me. The guid is meant to persist with the attachment post data, which means that if you moved the content twice, the original guid would persist as expected.

#2 @dd32
9 years ago

Although this might be the expected behaviour of the exporter/importer, it's most definately an incorrect assumption.

We shouldn't be relying upon the GUID for anything other than "This is item X", it should never be treated as a permanent URL.

#3 @dd32
9 years ago

  • Keywords close removed
Note: See TracTickets for help on using tickets.