Register Members List Search Today's Posts Mark Forums Read

Reply
 
Mod Options
Multiple Forums using a single user table Details »
Multiple Forums using a single user table
Mod Version: 1.00, by e2s (Member) e2s is offline
Developer Last Online: Mar 2009 I like it Show Printable Version Email this Page

This modification is in the archives.
vB Version: 3.5.4 Rating: (3 votes - 3.67 average) Installs: 48
Released: 13 Jun 2006 Last Update: Never Downloads: 5
Not Supported  

This was originaly done in 3.0.9 by westpointer you can view that thread here

This Modification is for VB3.5.4 This is not supported but I will give as much help as I possible can.

I have this working now on 2 sites

The main site is http://forums.everything2stroke.com

Slave sites are
http://forums.everythingmx.com
and
http://forums.everythingduners.com

After a successfull install of this modification your sites will share User, PM, and sesson data.

This thread will detail how to have a single login for multiple forums. It makes the following assumptions:
  • A valid vbulletin license exists for each install
  • All forums will be on the same server
  • One database will contain all the tables
A valid vbulletin license exists for each install


Follow these steps

1.) Download your new copy of VB that contains a seperate license key
2.) Go to /includes/config.php.new rename the file to config.php and make necessary changes to the file. See VB Directions. Make sure this code has a different setting than the master site for table prefix.


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

3.) Run the vb install from the new directory (/www/new_forums/install/install.php)

4.) During the install, be sure NOT to empty the tables. If you have any doubt about what this means, stop NOW! If you empty the tables, you will lose all of your existing data from a prior install!

5.) Download all files and directories to your PC from the new install location.

6.) You will need a tool to do a mass Search and replace on all files. I use WildEdit. Here is what you will do using a tool like Wild Edit.
  • Search for [" . TABLE_PREFIX . "user] Replace with [" . "vb3_user] where "vb3_" is the prefix to your master site. 110 Files modified 599 Total changes made
  • Search for [" . TABLE_PREFIX . "strikes] Replace with [" . "vb3_strikes] where "vb3_" is the prefix to your master site 4 Files modified 8 Total changes made
  • Search for [" . TABLE_PREFIX . "pm] Replace with [" . "vb3_pm] where "vb3_" is the prefix to your master site 16 Files modified 77 Total changes made
  • Search for [" . TABLE_PREFIX . "session] Replace with [" . "vb3_session] where "vb3_" is the prefix to your master site 20 Files modified 31 Total changes made

Now to modify some of the code.

In /include/class_dm.php

Search for:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Add below change vb3_ to your master site prefix:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.


Go to /include/class_dm_pm.php

Search for:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace with making vb3_ the prefix to your master site:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.


Search for:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace with where vb3_ is the prefix to your master site:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Search for:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace with where vb3_ is the prefix to your master site:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Search for:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace with where vb3_ is the prefix to your master site:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.


Go to /include/class_dm_user.php

Search for:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace with where vb3_ is the prefix to your master site:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Search for:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace with where vb3_ is the prefix to your master site:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Search for:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace with where vb3_ is the prefix to your master site:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Search for:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace with where vb3_ is the prefix to your master site:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Search for:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace with where vb3_ is the prefix to your master site:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Search for:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace with where vb3_ is the prefix to your master site:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Search for:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace with where vb3_ is the prefix to your master site:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Search for:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace with where vb3_ is the prefix to your master site:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Search for:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace with where vb3_ is the prefix to your master site:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.


That is all the code modification.


The only other item I did is remove a couple cron jobs.

Go into Scheduled tasks then to Scheduled Task Manager

Delete the following CRON jobs from the Slave Site

User Promotions*
Birthdays
Activation Reminder Email

This will eliminate members getting emails from the primary and secondary sites
*not sure if this will duplicate efforts between primary and secondary sites I have it running on both sites still waiting to see if it causes any issues.


Please post here if you have any problems and questions I will try my best to keep up with everyone to help you through this. Once you get the code done the first time you can just do a mass search and replace on your license code and you can be up and running in minutes with a new site.

This is my first major modification so I hope I posted this all correct, again Thanks to Westpointer for his original work without his post this would not have been possible.

Thanks

UPDATE:

Please make this changes it will allow you to make changes to usergroups in the subscription section and when editing a user.

admincp/adminfunctions.php
Search for

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace with

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Download Now

Only licensed members can download files, Click Here for more information.

Show Your Support

  • To receive notifications regarding updates -> Click to Mark as Installed.
  • This modification may not be copied, reproduced or published elsewhere without author's permission.
Comments
  #2  
Old 13 Jun 2006, 15:48
Ntfu2 Ntfu2 is offline
 
Join Date: Feb 2006
awesome, i will definetly be trying this out.

What if i have my sites on two different hard drives, but the same server. And MySQL for each is on the same disk as well.
Reply With Quote
  #3  
Old 13 Jun 2006, 16:08
e2s e2s is offline
 
Join Date: Nov 2004
If I understand correct you just have 2 hard drives in your server and the sites happen to be on opposite hard drives. As long as you are only running 1 MySql for both sites you shouldn't have any issues. The path to your install is in the Config.php this Modification is just changing were a second site looks for User, PM, and session data.

Now I have not done this with 2 existing forums. I have only created a new forum to attach to my existing forum. You could still do it with 2 existing forums but it would take a little more effort since you would have to merge your userdatabase and some PM's would be lost unless you could merge those as well. I have no experiance in doing this so I am not sure I could be of much help
Reply With Quote
  #4  
Old 13 Jun 2006, 16:11
e2s e2s is offline
 
Join Date: Nov 2004
Oh just for the record I have successfully made vBadvanced CMPS work on the slave site. There is just a few modification you need to make to the modules. If you are looking to do this PM me.

www.everythingmx.com

I hope to intergrate other products soon like Photopost but not sure when I will get to it.
Reply With Quote
  #5  
Old 13 Jun 2006, 16:45
Ntfu2 Ntfu2 is offline
 
Join Date: Feb 2006
awesome

im going to give it a shot with two existing forms and see how it goes
Reply With Quote
  #6  
Old 13 Jun 2006, 16:46
e2s e2s is offline
 
Join Date: Nov 2004
Just be sure you do a backup of your databse
Reply With Quote
  #7  
Old 13 Jun 2006, 21:07
RMS-Chef RMS-Chef is offline
 
Join Date: Aug 2003
How are paid subscriptions effected by this if at all?
If they buy a subscription on the slave site, does it effect anything on the existing main site?
__________________
Hi.
Reply With Quote
  #8  
Old 13 Jun 2006, 22:14
lovevn lovevn is offline
 
Join Date: May 2004
Hi
You are using your forums on different domains but I want to use it as the fllowing ways:

Master forum : mydomain.com/forum
Slave forum:forum/mydomain.com

Is it possible?

Thanks
Reply With Quote
  #9  
Old 14 Jun 2006, 07:21
Steve F's Avatar
Steve F Steve F is offline
 
Join Date: Mar 2003
This must be one of the most sought after hacks, great work e2s, thank you for sharing with us and thanks Westpointer for the original idea !

lovevn: I am sure it would work
__________________
vBulletin-Hungary.Com

Last edited by Steve F; 14 Jun 2006 at 07:25.
Reply With Quote
  #10  
Old 14 Jun 2006, 10:02
e2s e2s is offline
 
Join Date: Nov 2004
Originally Posted by lovevn
Hi
You are using your forums on different domains but I want to use it as the fllowing ways:

Master forum : mydomain.com/forum
Slave forum:forum/mydomain.com

Is it possible?

Thanks
If I understand correctly your just looking to point a subdomain forum to your forum directory. That can be done in your server config without even touching the code
Reply With Quote
  #11  
Old 14 Jun 2006, 10:04
e2s e2s is offline
 
Join Date: Nov 2004
Originally Posted by RMS-Chef
How are paid subscriptions effected by this if at all?
If they buy a subscription on the slave site, does it effect anything on the existing main site?
That is a great question but I don't have the answer. I know in the current setup all the usergroups are used by the slave sites so if a member is a paid member in the master site they will also be a paid member in the slave.

I will look into what it will take to get the subscription to work on the slave sites.
Reply With Quote
  #12  
Old 14 Jun 2006, 10:05
e2s e2s is offline
 
Join Date: Nov 2004
Originally Posted by Steve F
This must be one of the most sought after hacks, great work e2s, thank you for sharing with us and thanks Westpointer for the original idea !

lovevn: I am sure it would work
Thanks Steve, hopefully it will help some people out.
Reply With Quote
  #13  
Old 14 Jun 2006, 12:13
TheComputerGuy's Avatar
TheComputerGuy TheComputerGuy is offline
 
Join Date: Oct 2001
Real name: Joe
awesome hack e2s!
__________________
I'll buy your forum!
Reply With Quote
  #14  
Old 14 Jun 2006, 12:37
e2s e2s is offline
 
Join Date: Nov 2004
Originally Posted by RMS-Chef
How are paid subscriptions effected by this if at all?
If they buy a subscription on the slave site, does it effect anything on the existing main site?
Looks like this can be taken care of real easy I am going to try this today and if all works well i will post up the instructions. It should just be a mass Search and replace on table subscriptions and subscriptionlog


Thanks ComputerGuy
Reply With Quote
  #15  
Old 14 Jun 2006, 13:57
utw-Mephisto utw-Mephisto is offline
 
Join Date: Feb 2005
Originally Posted by e2s
I have no experiance in doing this so I am not sure I could be of much help
Can't you use Impex ? just wondering .
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Mod Options

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


New To Site? Need Help?

All times are GMT. The time now is 07:30.

Layout Options | Width: Wide Color: