Replies: 0
I have been struggling with this issue for a while and I do not seem to have found a final solution to it. I have two instances: staging and dev. I recently needed to create a 3rd instance from staging, so I went away and followed the usual process as described here. I have then done the following:
– export the post from the staging;
– import the post into the new instance;
– same process for media
– move the attachments/images into my new uploads folder and used the plugin Add from Server to fetch them from the server and moved them into the Media Library
– check whether the new DB had all the correct references (no old references coming from the other instance). This was done with the plugin Search and Replace.
My issue is the link between the articles/posts and their attachments (in my case mostly featured images). I know that the post that an attachment is related to is determined by the post_parent column on the wp_posts table (depending on your database prefix), but how I can make sure that the linkage is preserved and maintained during the migration?
Can you help?
Thank you