Black Friday Sale! Get $20 off GP Premium, $40 off our new Lifetime license, and 45% off license renewals/extensions! Learn more

[Resolved] Sections disappear in migrated site

Home Forums Support Sections disappear in migrated site

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #446997
    Daniel Walker

    Hi there, after migrating my website database from my live server into a new localhost database, my sections don’t appear in my localhost pages.

    I can, however, see the sections’ content in wp_postmeta.meta_value, they’re just not showing up on the local site/WP dashboard.

    I get the following errors:
    Warning: Invalid argument supplied for foreach() in C:\xampp\htdocs\newLocal\wp-content\plugins\generate-sections\functions\generate-sections.php on line 159

    Warning: Invalid argument supplied for foreach() in C:\xampp\htdocs\newLocal\wp-content\plugins\generate-sections\functions\templates\generate-sections-page-template.php on line 39

    I am running GeneratePress 1.3.27 (with a child theme) and GenerateSections 1.0.14

    Any ideas what might have gone wrong during migration?

    Thanks in advance.
    Dan

    #447081
    Tom
    Lead Developer
    Lead Developer

    Since Sections are serialized entries, you can’t do any manual search/replacing of URLs in the database.

    I would re-start the migration and use a plugin like Duplicator, All in One Migration, or even Velvet Blues Update URLs. They all take serialized options into account when replacing URLs.

    #447640
    Daniel Walker

    Thanks Tom. I’ve used Duplicator for migrations before, so can go back to that. In this instance I just wanted to try a manual migration but now I can see how the serialised data would get messed up by updating the URLs in phpMyAdmin.

    #447875
    Tom
    Lead Developer
    Lead Developer

    Confused me pretty good once too.

    You can still do a manual migration, just use a plugin like Velvet Blues Update URLs to do the URL search/replace 🙂

    #447900
    Daniel Walker

    I did get it working with Better Search and Replace, although I still had to re-publish some sliders that couldn’t find their background images for some reason.
    Thanks again.
    Dan

    #448205
    Tom
    Lead Developer
    Lead Developer
Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.