Problem with img-links (and srcset) when migrating site using Duplicator plugin

Posted in: Newspaper
Post count: 137

I am doing some testing for an up and coming migration of my site to a new host. Have found that the Duplicator plugin (https://wordpress.org/plugins/duplicator/) seems to be working really well.

I do understand if this is not something you have anything to do with but I thought the question might be somwhat theme-related anyway, since it is about how the image-links get treated after the migration.

A lot of pictures within the theme uses the srcset-tag do display a smaller version of a certain picture. The srcset-links does get updated to the new address after the move. However they get updated in the wrong way.

Some images display correctly (that aren´t using the srcset-code). The actual image-link (src) is correct on both the images that uses the srcset and the ones that doesn´t. The path to the actual picture the looks like this:
src="http://localhost/test/wp-content/uploads/2016/11/picture.jpg

The srcset pictures also (as stated) have the correct src-path, but the srcset-path (that actually displays the image) gets this path after the migration:
srcset="http://localhost/test/C:/xampp/htdocs/test/wp-content/uploads/2016/11/picture.jpg

They get the “C:/xampp/htdocs/test” added into the path, and that makes them not visible at all.

Is there some kind of reset setting in the theme-settings to change this or delete the “C:/xampp/htdocs/test” before every picture?

Thanks
Christoffer

Post count: 9544

The srcset image links are built into WordPress and not actually theme specific. That is something WordPress started a couple of versions back.

Note that doing a resurrection to a local host will change the paths vs doing a domain to domain move.

So, likely need to look at the DUPLICATOR docs.

I did a move from one site earlier this year, where I also renamed it, and everything when perfeclty, but I was moving from /server/path to /server/path — not /server/path to /xampp/localpc paths.

SO, something in how you’re doing that is what is causing the issue.

Of course, you can simply do a mysql search/replace for paths after the move/restore too.

ANyway — theme has nothing to do with that.

Post count: 137

Thanks for confirming its not a theme issue. Shouldn’t the migration be the same for localhost vs an actual host. I mean, both have paths pointing to the actual files (before the actual www-root).

Has anyone else experienced similar issues with Duplicator? If I could get this to work it would help the world instead of having to make a fresh install and importing everything and re-uploading/naming featuerd pictures etc etc…

Post count: 22421

Sorry but we have not tested this plugin so I cannot provide any official solution for your issue. Maybe one of our users who experienced this can help.

Thank you!

Viewing 4 posts - 1 through 4 (of 4 total)
The forum ‘Newspaper’ is closed to new topics and replies.