• I have two wordpress sites for my Persian and English users like this:
    http://www.samasarin.com (for persian users)
    http://www.samasarin.com/english (for English users)
    I had installed wordpress separately on this sites. on another word, I have two wordpress sites!
    I have a order form on both sites but those datas save in two seperated database.
    How can I save these submited datas on one database?

    • This topic was modified 9 years, 4 months ago by Sama.
Viewing 1 replies (of 1 total)
  • AddWeb Solution

    (@addweb-solution-pvt-ltd)

    Hi samasarin,

    Install 2 WordPress sites on a single database follow below steps:

    => Create new table in your database. Call it wp_options2 and copy everything from wp_options into this new table

    => In second install go to wp-config.php, and before if (!defined(‘ABSPATH’)) add define( ‘M7_OPTIONS_TABLE’, ‘wp_options2’);

    => In second install go to wp-includes/wp-db.php on line 1009 and add code:

    => if (isset( $tables[‘options’] ) && defined(‘M7_OPTIONS_TABLE’)) $tables[‘options’] = M7_OPTIONS_TABLE;

    => These codes should be added in public function tables function, before if (isset( $tables[‘users’]) && defined(‘CUSTOM_USER_TABLE’)))

    => Now you should be able to change theme, plugins etc. for seccond theme, but all posts, taxonomies etc. will be dubbled in both websites ( wich is bad for seo bdw. )

    => if on seccond install you’ll have some problems with links, add define(‘WP_HOME’,’http://seccond_website.com’);
    define(‘WP_SITEURL’,’http://seccond_website.com’); in your wp-config.php file .

    Hope this step is usefull for your purpose.

    Thank you.

Viewing 1 replies (of 1 total)

The topic ‘two sites with one database for particular plugin’ is closed to new replies.