Synchronization with multiple sites and one BDD Dolphin

pierrehs posted 4th of November 2010 in Community Voice. 5 comments.

 

Hello,

I managed to sync automatically with all the default modules on several sites of Dolphin Dolphin

All sites use the same database

but all files have their own directory on their site Dolphin (photos, videos, files, etc.).

So it is very easy to have multiple sites Dolphin with different themes (dating, social network, video platform etc..) and keep the same database.

 

But I wonder if this technique is correct

I think what makes extensive use of server resources

but I can not confirm

 

Here's what I did:

Install your main Dolphin site that will share this data and its database with other sites

EX: http://yourdomain.com

 

Then install each site depending on the main site in Dolphin subdirectory

EX:

http://videos-zone.yourdomain.com

http://dating.yourdomain.com

http://social-network.yourdomain.com

http://chat-webcam.yourdomain.com

 

Then after installation

 

appointment for each sub-domain site in the directory inc/header.inc.php

 

 

and modify as below by substituting with your information:

As "your-subdomain" by your subdomain (EX : dating.yourdomain.com, social-network.yourdomain.com, videos-zone.yourdomain.com ...) and "yourdomain.com"

by the domain name of your site

 

and other information

Database, full path  ("/home/you/public_html/)...

 

 

 

 

$site['ver']               = '7.0';
$site['build']             = '3';
$site['url']               = "http://your-subdomain.yourdomain.com/";
$admin_dir                 = "administration";
$iAdminPage				= 0;
$site['url_admin']         = "{$site['url']}$admin_dir/";

$site['mediaImages']       = "{$site['url']}media/images/";
$site['gallery']           = "{$site['url']}media/images/gallery/";
$site['flags']             = "{$site['url']}media/images/flags/";
$site['banners']           = "{$site['url']}media/images/banners/";
$site['imagesPromo']       = "{$site['url']}media/images/promo/";
$site['tmp']               = "{$site['url']}tmp/";
$site['plugins']           = "{$site['url']}plugins/";
$site['base']              = "http://yourdomain.com/templates/base/";

$site['bugReportMail']     = "your-mail@yourdomain.com";

$dir['root']               = "/home/you/public_html/your-subdomain/";
$dir['inc']                = "{$dir['root']}inc/";
$dir['profileImage']       = "{$dir['root']}media/images/profile/";

$dir['mediaImages']        = "{$dir['root']}media/images/";
$dir['gallery']            = "{$dir['root']}media/images/gallery/";
$dir['flags']              = "{$dir['root']}media/images/flags/";
$dir['banners']            = "{$dir['root']}media/images/banners/";
$dir['imagesPromo']        = "{$dir['root']}media/images/promo/";
$dir['tmp']                = "{$dir['root']}tmp/";
$dir['cache']              = "{$dir['root']}cache/";
$dir['plugins']            = "{$dir['root']}plugins/";
$dir['base']               = "/home/you/public_html/templates/base/";
$dir['classes']            = "{$dir['inc']}classes/";

$video_ext                 = 'avi';
$MOGRIFY                   = "/usr/bin/mogrify";
$CONVERT                   = "/usr/bin/convert";
$COMPOSITE                 = "/usr/bin/composite";
$PHPBIN                    = "/usr/local/bin/php";

$db['host']                = 'localhost';
$db['sock']                = '';
$db['port']                = '';
$db['user']                = 'master_user';
$db['passwd']              = 'password_master_database';
$db['db']                  = 'master_database';

define('BX_DOL_URL_ROOT', $site['url']);
define('BX_DOL_URL_ADMIN', $site['url_admin']);
define('BX_DOL_URL_PLUGINS', $site['plugins']);
define('BX_DOL_URL_MODULES', 'http://yourdomain.com/modules/' );
define('BX_DOL_CACHE_PUBLIC', $site['url'] . 'cache_public/');

define('BX_DIRECTORY_PATH_INC', $dir['inc']);
define('BX_DIRECTORY_PATH_ROOT', $dir['root']);
define('BX_DIRECTORY_PATH_BASE', $dir['base']);
define('BX_DIRECTORY_PATH_CACHE', $dir['cache']);
define('BX_DIRECTORY_PATH_CLASSES', $dir['classes']);
define('BX_DIRECTORY_PATH_PLUGINS', $dir['plugins']);
define('BX_DIRECTORY_PATH_DBCACHE', $dir['cache']);
define('BX_DIRECTORY_PATH_MODULES', '/home/you/public_html/modules/' );
define('BX_DIRECTORY_PATH_CACHE_PUBLIC', $dir['root'] . 'cache_public/' );

define('DATABASE_HOST', $db['host']);
define('DATABASE_SOCK', $db['sock']);
define('DATABASE_PORT', $db['port']);
define('DATABASE_USER', $db['user']);
define('DATABASE_PASS', $db['passwd']);
define('DATABASE_NAME', $db['db']);

 

 

After you clear the cache of each site dependent and delete their databases

WARNING: This works for me

I did the test on a site with over 6000 profiles, 8500 photos and 60 videos.

The modules work well but I'm really not sure this is a good technique I await the advice of a professional Dolphin will tell me

 

Again I'm really not sure it is correct for the server such a technique

 

 
Recommended by
 
 
Comments
·Oldest
·Top
Please login to post a comment.
tomakali
Congrats! Build a Mod. Thatd be useful
adultnet
Can it be done with different domains instead of subdomains ?
michaeljdornan
Has anyone else done this? does it actually work?
italian-backtracker
this is the very best hack mod!!!
Is there a possibilty with this mod to have an International Boonex community that works language with mail templates in native language on the user?

http://english.yourdomain.com ------> if user registered here all dolphin in english (calendar, chat, script, etc.. )

http://italian.yourdomain.com ------> if user registered here all dolphin in italian (calendar, chat, script, etc.. )

http://francais.yourdomain.com ------> if user see more registered here all dolphin in francais (calendar, chat, script, etc.. )

http://deutch.yourdomain.com ------> if user registered here all dolphin in deutch (calendar, chat, script, etc.. )
mlbs
tried this it works and doesnt work! it does sync datbase but again causes other problems

1. license doesnt work in subdomain as well as main domain
2. you have to use same template in all sites
3. navagation menu if you change in sub-domain you cant edit main domain as admin is the same
4. admin is also all sync up so as you can see with #3 you cant have diffrent admin for each site

I f you want to have all your site identical then this would work somewhat but the idea i thought was to see more have diffrent! (not identical) sites using one database

this is just my test so would love to hear if anyone else has tried this and been succesful
 
 
Below is the legacy version of the Boonex site, maintained for Dolphin.Pro 7.x support.
The new Dolphin solution is powered by UNA Community Management System.
PET:0.1239378452301