Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 General Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 04-21-2005, 06:08 AM
ChrisHasenpflug ChrisHasenpflug is offline
 
Join Date: Apr 2005
Location: Kansas City, MO
Posts: 12
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default One user/post database, multiple sites

Hi folks,

I'm going to be converting to vB for a network of sites. All of these sites will use their own design and marketing tactics. However, they all use the same database. Same users, same forums/subforums, same posts. Only difference is the templates and the content in their CMS.

I'm currently working through this in a dev enviroment and its not as easy as I had hoped (we currently do this with UBB just fine).

First thing, when setting up the second site I couldn't go through the install since the tables were already created. But I was able to login and view the posts since the DB was setup for site 1.

Problem 1: site2 has the title of site1. This is (I assume) because the site name is actually stored in the database. Uh oh! This won't do at all, how do I get around that?

Problem 2: Templates are stored in the database. Any changes to site2 will be reflected on site1 and viceaversa.

How do I make this possible?? Thoughts?? I'm and experienced php & mySQL programmer, but I haven't sat down with the vB code yet to hack through it. Hopeful somebody can give me some pointers!

Thanks in advance!
Reply With Quote
  #2  
Old 04-21-2005, 07:11 AM
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Posts: 25,415
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

If i understand you correctly, then this can not be done easily and would even be against your license agreement, unless you would buy a seperate license for each site.
Reply With Quote
  #3  
Old 04-21-2005, 07:14 AM
ChrisHasenpflug ChrisHasenpflug is offline
 
Join Date: Apr 2005
Location: Kansas City, MO
Posts: 12
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

We would indeed have seperate licenses for each site.
Reply With Quote
  #4  
Old 04-21-2005, 07:39 AM
Brad Brad is offline
 
Join Date: Nov 2001
Posts: 4,765
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Use a table prefix if both forums are to be in the same database. The reason board two acts like board one is the php files are using board one's tables.
Reply With Quote
  #5  
Old 04-21-2005, 07:44 AM
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Posts: 25,415
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ok, let me try to get things clear. From what i understand you want:
- 1 Board, ie. 1 database with users, forums and posts.
- Different domains all leading to this same Board. Depending on the domain you want to present a different style and frontpage.

Just making some educated guess now, because i never tried it but i think you could modify vB to do the following (would need some work):
- Setup 1 Board
- Add styles for each subdomain
- Create an additional table linking domains to styleid's
- Check the domain/style on each page load and set accordingly.
- Create a table to hold the Titles for each domain and use that to override the default Sitename
- The changes needed to a CMS would depends on which CMS you choose to use.

You will probably need to add some caching to prevent performance going down.
Reply With Quote
  #6  
Old 04-21-2005, 07:45 AM
ChrisHasenpflug ChrisHasenpflug is offline
 
Join Date: Apr 2005
Location: Kansas City, MO
Posts: 12
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Brad.loo
Use a table prefix if both forums are to be in the same database. The reason board two acts like board one is the php files are using board one's tables.
But I don't want them to act seperatly. I want the users and the posts to replicate across multiple sites.

Same content, different design/style.
Reply With Quote
  #7  
Old 04-21-2005, 07:47 AM
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Posts: 25,415
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

PS There will be more caveats in this then i have now mentioned.
Reply With Quote
  #8  
Old 04-21-2005, 07:51 AM
ChrisHasenpflug ChrisHasenpflug is offline
 
Join Date: Apr 2005
Location: Kansas City, MO
Posts: 12
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by MarcoH64
Ok, let me try to get things clear. From what i understand you want:
- 1 Board, ie. 1 database with users, forums and posts.
- Different domains all leading to this same Board. Depending on the domain you want to present a different style and frontpage.

Just making some educated guess now, because i never tried it but i think you could modify vB to do the following (would need some work):
- Setup 1 Board
- Add styles for each subdomain
- Create an additional table linking domains to styleid's
- Check the domain/style on each page load and set accordingly.
- Create a table to hold the Titles for each domain and use that to override the default Sitename
- The changes needed to a CMS would depends on which CMS you choose to use.

You will probably need to add some caching to prevent performance going down.
Marco, thank you for your response. An interesting approach indeed. I think it may work out well.

I'm curious where in the vB code I would check for the domain and set the templates/styles to use.

I find it quite interesting that this situation seems to be more difficult in vB, a more advanced BBS, then it was in UBB, a highly inferior product.

Quote:
PS There will be more caveats in this then i have now mentioned.
What comes to mind?? I don't expect a full evaluation, but I'm just curious as to what initally comes to mind.
Reply With Quote
  #9  
Old 04-21-2005, 08:14 AM
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Posts: 25,415
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Some things that would come into my mind are:
- With multiple boards licenses, you would normally use seperate forumhome directories, each with their own software (php-files) installed, containing their own licensenumber. Licensenumber is also used to hash the password set in the cookie for the domain. So would be a difficult decission which way to go: single software directory (you still should have bought the licenses) or multiple. This would also effect the way hacks are installed, the same for all?
- Cookie handling in General
- How to keep this manageable.
- How to setup the CMS
- Handling 1 user who is browsing more then 1 site at the same time.
- ...

I am sure all could be solved, but it might need some serious coding.
Reply With Quote
  #10  
Old 04-21-2005, 08:15 AM
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Posts: 25,415
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by ChrisHasenpflug
I'm curious where in the vB code I would check for the domain and set the templates/styles to use.
At a very high level so you can do this with less coding and still can be sure ti works everywhere. Somewhere in global.php or init.php i would say.
Reply With Quote
Reply


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

Forum Jump


All times are GMT. The time now is 06:43 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04424 seconds
  • Memory Usage 2,252KB
  • Queries Executed 13 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (4)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete