[Forminator Pro] is their a way to transfer forminator submissions to my new subsite from the old?

I recently transferred a website of mine from its subsite on one multisite network to a new subsite on a new multisite network but the forminator submissions didn’t follow.  how now after everything is all moved over (except these) can I get them into my new site?

  • Luigi Di Benedetto
    • Staff

    Hi Tracy Renee

    I hope you’re having a great day.

    Unfortunately, by default, Forminator doesn’t provide a built-in feature to import submissions from a CSV file. However, we have a workaround that involves creating a mu-plugin.

    Here are the steps to achieve this:

    1. Export the submissions of the desired form to CSV by going to the submissions page, selecting the form you want, and clicking on the export option on the right.

    2. Upload your CSV exported file to the “/wp-content/uploads” folder of your site using FTP or a similar method.

    3. Use this custom script from the following link: (https://gist.github.com/wpmudev-sls/c388628c027364aa866e4d1c329f5b5d)

    4. Edit the following two lines in the script:
    $form_id = 7;: Replace 7 with the ID of the form where you want to import data.
    $csv_filename = "forminator-simple-contact-form-211019093636";: Set the file name of your CSV file (the one you uploaded to /wp-content/uploads). Note that you should not include the full path or the .csv extension.

    5. Save the code in a file with a .php extension (e.g., “import-forminator-submissions.php”).

    6. Add this file to your site as an MU plugin. You can follow this guide to learn how to do that: (https://wpmudev.com/docs/using-wordpress/installing-wordpress-plugins/#installing-mu-plugins).

    7. Once you’ve added the MU plugin, visit your site. The data should be imported. Make sure to remove the plugin from your site right after the data is imported.

    I hope these instructions are helpful. If you have any more questions or need further assistance, please feel free to ask.

    Best regards,
    Luigi.

    • Tracy Byrne
      • The Incredible Code Injector

      7. Once you’ve added the MU plugin, visit your site. The data should be imported. Make sure to remove the plugin from your site right after the data is imported.

      Well, I did everything very carefully step by step as you outlined and … nothing. But, here’s a question… how long should it take to do the data import? there are a lot of lines of data in the csv file.

  • Amin Nazemi
    • Staff

    Hi Tracy Renee

    I’ve tested the code on my lab site and I can confirm its working fine, you just need to make sure you entered the correct file name and form ID (form ID can be found on the form edit link or form shortcode).
    [attachments are only viewable by logged-in members]

    how long should it take to do the data import? there are a lot of lines of data in the csv file.

    It should not take more than a few seconds and keep that in mind the function runs with each page refresh, you should remove it once the submissions are imported otherwise it creates duplicate data.

    Best Regards
    Amin