Links to local URL cached in Cornerstone?

Using the Duplicator plugin, I have successfully brought sites down to my local environment, updated them to X, and published back to the existing domain.

Using the latest version of X, I’ve pulled down a site, made all changes, then published. When browsing the site, everything looks great. However, when I go to edit a page that was created with Cornerstone, it reverts all the links back to localhost.

Using PHP myAdmin I’ve run several scripts to update the URLs back to the production URL, however when editing the page, it again reverts to the local URL.

Where is Cornerstone holding the cache, and how can I prevent this from happening?

The host is MediaTemple, but it is on a shared server, not the dedicated WP hosting, so there’s no cache to clear on their end.

UPDATE: This issue appears to occur only for those pages that were imported from a template where the template made reference to the local site.

UPDATE 2: In case anyone else comes across this, the issue seems to be that when you import from a template, in the the wp_postmeta, the forward slashes in the URL path are escaped. The result is that the Duplicator plugin updates un-escaped URLs, but not the ones that are escaped.

When I ran this script, the changes seem to persist and the issue is resolved:
UPDATE wp_postmeta SET meta_value = replace(meta_value,‘http://localhost/domain’,'https://www.domain.ca’);

I have no idea why things work when first published, but not when pages are edited if you omit this step.

Hi there,

Thank you for sharing your solution regarding this case.

Cheers.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.