Images added to target site get incorrect GUID
-
When I broadcast a post to a site, the image links are broken. The images themselves (from the IMG tag) still work because they aren’t being updated to point to the newly added images on the target site, they are still pointing to the source site. Not sure if this is intentional or not ( I assume not, in which case that’s a problem too ). However, the bigger problem is the HREF links to those images (when the images are chosen to “link to media file” in WP) are modified in an attempt (I assume) to point to the target site’s media file. However, the link is wrong.
For one example, the link is being translated to–
https://www.abington.k12.pa.us/junior/junior/media/sites/junior/2016/02/pic2.jpg
but it should be
https://www.abington.k12.pa.us/junior/media/sites/junior/2016/02/pic2.jpg
… note the extra “/junior” being added in there.where “https://www.abington.k12.pa.us” is the main site / source and “https://www.abington.k12.pa.us/junior” is the sub site / target.
When I did a debug I see this:
2016-02-18 14:56:19 ThreeWP_Broadcast: 3 attachments to remove. 2016-02-18 14:56:19 ThreeWP_Broadcast: Deleting existing attachment: 1666 2016-02-18 14:56:19 ThreeWP_Broadcast: Deleting existing attachment: 1667 2016-02-18 14:56:19 ThreeWP_Broadcast: Deleting existing attachment: 1665 2016-02-18 14:56:19 ThreeWP_Broadcast: Looking through 3 attachments. 2016-02-18 14:56:19 ThreeWP_Broadcast: The attachment's post parent is 5399. 2016-02-18 14:56:19 ThreeWP_Broadcast: Assigning new post parent ID (1611) to attachment 5410. 2016-02-18 14:56:19 ThreeWP_Broadcast: Maybe copy attachment: Searching for attachment posts with the name broadwaylogo. 2016-02-18 14:56:19 ThreeWP_Broadcast: Maybe copy attachment: Found 0 attachment posts. 2016-02-18 14:56:19 ThreeWP_Broadcast: Maybe copy attachment: Really copying attachment. 2016-02-18 14:56:19 ThreeWP_Broadcast: Copy attachment: File "D:\inetpub\admin/media/posts/2016/02/broadwaylogo.jpg" is on local file-system 2016-02-18 14:56:19 ThreeWP_Broadcast: Copy attachment: Copying from D:\inetpub\admin/media/posts/2016/02/broadwaylogo.jpg to D:\inetpub\admin/media/sites/junior/2016/02/broadwaylogo.jpg 2016-02-18 14:56:19 ThreeWP_Broadcast: Copy attachment: File sizes: D:\inetpub\admin/media/posts/2016/02/broadwaylogo.jpg 169236 ; D:\inetpub\admin/media/sites/junior/2016/02/broadwaylogo.jpg 169236 2016-02-18 14:56:19 ThreeWP_Broadcast: Copy attachment: Checking filetype. 2016-02-18 14:56:19 ThreeWP_Broadcast: Copy attachment: Inserting attachment: array ( 'guid' => 'https://www.abington.k12.pa.us/junior/junior/media/sites/junior/2016/02/broadwaylogo.jpg', 'menu_order' => 0, 'post_author' => '3', 'post_excerpt' => '', 'post_mime_type' => 'image/jpeg', 'post_name' => 'broadwaylogo', 'post_title' => 'broadwaylogo', 'post_content' => '', 'post_status' => 'inherit', )
The ‘guid’ there is incorrect, and I assume that is what is being used in the link.
- The topic ‘Images added to target site get incorrect GUID’ is closed to new replies.