Author |
Message |
nexusucx
New Member


Joined: Jan 19, 2011
Posts: 6
|
Posted:
Sat Jan 14, 2012 5:01 pm |
|
Hi guys.
Just wondering if it is possible to have two sites running off one database.
I have quite a large clan that play the cod and bf series of games. I want to have a site for each game but I dont want them to have to register twice.
What I want to do is have just one database for the 2 sites.
Now that would solve the dual login issue but i would also need a "hack" to have two sets of forums running so that only relevant forums for each site are available.
So can I:
a) have one database running the two sites.
b) have more than one set of forums in that database (ie: Forums and Forums1 (file structure) where Forums is visable in site 1 and Forums1 is visable in site 2)
Thanks in advance.
ps hope this is the right place to post this.. |
|
|
|
 |
nuken
RavenNuke(tm) Development Team

Joined: Mar 11, 2007
Posts: 2024
Location: North Carolina
|
Posted:
Sat Jan 14, 2012 6:05 pm |
|
If the sites are all using the same database on the same server, in the config.php of each site you can use different $prefix for each install and have all of them with the same $user_prefix. Some older modules or hacks may not work correctly, but most should. |
_________________ Only registered users can see links on this board! Get registered or login! |
|
|
 |
nexusucx

|
Posted:
Sat Jan 14, 2012 6:10 pm |
|
What it will be is 2 fresh installs of the latest RavenNuke on a single database on the same server.
So all i need to do then is on site 2 is change the $prefix so it differs from site one but have both sites use the same $user_prefix. That way they would have seperate forums etc etc but the users would stretch across both sites saving them from having to register on both sites.. |
|
|
|
 |
nuken

|
Posted:
Sat Jan 14, 2012 6:14 pm |
|
Should be. I have never tried it personally, but I believe that was the intention of the different prefix for users.... |
|
|
|
 |
killing-hours
RavenNuke(tm) Development Team

Joined: Oct 01, 2010
Posts: 438
Location: Houston, Tx
|
Posted:
Mon Jan 16, 2012 10:58 am |
|
Wouldn't it be better to keep the sites in two separate databases and run a cron job to more or less sync the users table from one site to the other?
Edit***
Hrm... I retract this first statement. The auto increments will get messed up doing this.... however, if you try to run multiple websites from one database... don't you just end up with two replica websites?
How do you determine the theme for Website A vs. Website B from one database? Same for news posts for Website A vs. Website B? etc etc etc. |
_________________ Money is the measurement of time - Me
"You can all go to hell…I’m going to Texas" -Davy Crockett |
|
|
 |
nuken

|
Posted:
Mon Jan 16, 2012 1:37 pm |
|
The only thing shared should be the users and not the other tables. By changing the $prefix, you have a complete separate site with it's own tables. The $user_prefix would be the only tables shared and that should only be the tables for your account. |
|
|
|
 |
killing-hours

|
Posted:
Mon Jan 16, 2012 1:46 pm |
|
Ah you are correct. I had a run in previously with $user_prefix but I had a different understanding of what it was used for. (apparently that understanding was incorrect)
BTW... did you switch to mint permanently now? I see you changed your avatar.  |
|
|
|
 |
Guardian2003
Site Admin

Joined: Aug 28, 2003
Posts: 6799
Location: Ha Noi, Viet Nam
|
Posted:
Mon Jan 16, 2012 2:08 pm |
|
killing-hours wrote: | ... did you switch to mint permanently now? |
I have
Mint with Cinnamon and Muffin |
|
|
|
 |
killing-hours

|
Posted:
Mon Jan 16, 2012 2:27 pm |
|
Guardian2003 wrote: | killing-hours wrote: | ... did you switch to mint permanently now? |
I have
Mint with Cinnamon and Muffin |
Topped with poppy seeds? mmmmmmmm |
|
|
|
 |
hicuxunicorniobestbuildpc
The Mouse Is Extension Of Arm

Joined: Aug 13, 2009
Posts: 1123
|
Posted:
Mon Jan 16, 2012 9:40 pm |
|
|
|
 |
Guardian2003

|
Posted:
Tue Jan 17, 2012 1:58 am |
|
|
|
 |
|