XF 2.1 Which tables do I need to export/import for widgets & custom thread fields?

Stuart Wright

Well-known member
Hi folks,
I'm migrating AVForums to XF2 soon and I have set up much of the site on an XF2 sandbox for testing.
I need to export certain elements of the setup so I can quickly import it into the newly migrated site.
Specifically widgets and custom thread fields.
What tables do I need to export and re-import please?
Since the sandbox and the live site are on different servers, I will have to use phpmyadmin to export to SQL from the sandbox and then run that SQL on the migrated live site.
Thanks
 
Hi folks,
I'm migrating AVForums to XF2 soon and I have set up much of the site on an XF2 sandbox for testing.
I need to export certain elements of the setup so I can quickly import it into the newly migrated site.
Specifically widgets and custom thread fields.
What tables do I need to export and re-import please?
Since the sandbox and the live site are on different servers, I will have to use phpmyadmin to export to SQL from the sandbox and then run that SQL on the migrated live site.
Thanks

Stu, when I moved my site I created an add-on that did my template modifications and setup my widgets.

Below is how to include widgets and widget positions in the setup file. (taken from dev docs)

PHP:
public function installStep4()
{
    $this->createWidget('demo_portal_view_members_online', 'members_online', [
        'positions' => ['demo_portal_view_sidebar' => 10]
    ]);

    $this->createWidget('demo_portal_view_new_posts', 'new_posts', [
        'positions' => ['demo_portal_view_sidebar' => 20]
    ]);

    $this->createWidget('demo_portal_view_new_profile_posts', 'new_profile_posts', [
        'positions' => ['demo_portal_view_sidebar' => 30]
    ]);

    $this->createWidget('demo_portal_view_forum_statistics', 'forum_statistics', [
        'positions' => ['demo_portal_view_sidebar' => 40]
    ]);

    $this->createWidget('demo_portal_view_share_page', 'share_page', [
        'positions' => ['demo_portal_view_sidebar' => 50]
    ]);
}
 
Top Bottom