vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   How everything works? (https://vborg.vbsupport.ru/showthread.php?t=73984)

bkbelew 01-08-2005 05:08 AM

How everything works?
 
Hello,

Anyone have or willing to type up a layout of exactly how the vb backend works, like what happens when you hit the index, ie, init.php is loaded etc. Im trying to make the install I have share a database with another. And I cant seem to find anything. I cant find where vb defines what $user is, I cant find where the database query it for the $user string. I need to change the the prefix for the $user string.. Since I have one installed with no prefix, and the other with testvb_ I know it will end up being alot of changes to vb, that I dont mind.. I have nothing better to do ;) I just cant figure out how its layed out, where variables are stored.. etc etc.. Can anyone help? Also, just in case I dont end up figuring this out, does anyone have a script to copy any new content from one user db, to another?

Brandon
fraghard.com

Zachery 01-08-2005 05:09 AM

Pay me 1 Million dollars and give me about a year:) I'll give you all the tech docs you want.

At the moment there is no intensive docs like what you want, best off to ask a question and someone will anwser.

bkbelew 01-08-2005 03:02 PM

Mainly all I want to know is where the $user variable is set. I could care less about a extensive tech doc, it would just make it easier ;) I dont mind working, and searching.. this damn variable is being a real $#%$^ to find though.

rake 01-08-2005 04:29 PM

The user variable is set 86 times all across the vbulletin files. Which file are you looking at?

bkbelew 01-08-2005 04:31 PM

Im just wanting to change the $user query to look at a different table prefix

Zachery 01-08-2005 06:11 PM

Quote:

Originally Posted by bkbelew
Im just wanting to change the $user query to look at a different table prefix

Still going to require you changing alot of files.

Tigga 01-08-2005 06:23 PM

Quote:

Originally Posted by bkbelew
Im trying to make the install I have share a database with another.

That's going to require a LOT of work. The user table is queried in probably about 80% of the files. I'm not really understanding how adding a prefix to the user table is going to help with sharing a database though...

bkbelew 01-08-2005 06:28 PM

I wouldnt mind changing the code in every file if i knew what code to change ;) I know itll be alot of work.. doesnt bother me.. i have alot of time.

Quote:

That's going to require a LOT of work. The user table is queried in probably about 80% of the files. I'm not really understanding how adding a prefix to the user table is going to help with sharing a database though...
The two installs are in the same database, one has a prefix and one doesnt... to me, changing the prefix of the one with to a blank prefix, only on the user tables.. would make it read from the same table correct? Im new to all of this.. im just guessing with alot of it.. Im just looking for a little snippet of info that can help me :) My boss wants this done.. and doesnt want to pay.. so either I learn php.. and quick.. or i find someone to set me in the right direction :nervous: Any help would be greatly appreciated :ninja:

Zachery 01-08-2005 06:59 PM

Quote:

Originally Posted by bkbelew
I wouldnt mind changing the code in every file if i knew what code to change ;) I know itll be alot of work.. doesnt bother me.. i have alot of time.



The two installs are in the same database, one has a prefix and one doesnt... to me, changing the prefix of the one with to a blank prefix, only on the user tables.. would make it read from the same table correct? Im new to all of this.. im just guessing with alot of it.. Im just looking for a little snippet of info that can help me :) My boss wants this done.. and doesnt want to pay.. so either I learn php.. and quick.. or i find someone to set me in the right direction :nervous: Any help would be greatly appreciated :ninja:

I've already done it, (setting up the successfull use of one user datbase for two forums) its not pretty work, and it requires alot of time.

bkbelew 01-08-2005 07:02 PM

Give me some hints, lol.. please please.. I dont mind if its not pretty work.. and requires alot of time.. i need a challenge from time to time. But when you know nothing of how something works, it makes it near impossible to do anything with it.

Zachery 01-08-2005 07:11 PM

Well after spending a great deal of time with vBulletin pokeing and reading source code i have a decent understadnig,

Stage one would be installing 1 board the first, then modifiing all the files removing ' . TABLE_PREFIX . ' from every occurence that appears before user in every file.

once thats done, you move onto stage 2.

rake 01-08-2005 08:02 PM

Go get Editplus 2 and use the search and replace in files feature. Search for " . TABLE_PREFIX . "user and replace with: user

and tada! you've changed all the references to the user table in under 30 seconds. :)

bkbelew 01-08-2005 08:03 PM

Ive already got the majority of it done ;) well.. everything in the root is changed. My memberlist shows all the members from my other forum, and I can login under my username at the other forum.. doesnt keep my logged in though.. im sure thats in the includes somewhere.

bkbelew 01-08-2005 08:28 PM

Ok, heres heres another question, is users all i change, or do i have to change sessions? etc etc Ive had it sharing the user database, but it wouldnt log me in for some reason, it would say i was, but after it redirected back to where i was.. i wouldnt be.

bkbelew 01-08-2005 10:03 PM

Quote:

Originally Posted by bkbelew
Ok, heres heres another question, is users all i change, or do i have to change sessions? etc etc Ive had it sharing the user database, but it wouldnt log me in for some reason, it would say i was, but after it redirected back to where i was.. i wouldnt be.

Ok, i got it reading from the database.. i dont know if the admin settings are off or something, but for some reason, it wont let me login as admin, with my login from the other site

bkbelew 01-09-2005 02:08 AM

:update: got it all working, took me less then 2 hours ;) Thanks for the info Zachery

Zachery 01-09-2005 05:26 AM

Quote:

Originally Posted by bkbelew
:update: got it all working, took me less then 2 hours ;) Thanks for the info Zachery

Well if thats all you needed thats good, you are aware that this does require two licenses right? (to run two forums)


The messy stuff comes when you want to have specfic post counts for each forum, etc.

bkbelew 01-09-2005 05:29 AM

The post counts and what not dont matter to me. I do know that I have to get another license. After we run some tests on this one to make sure its not going to die we are going to purchase another.. probably monday morning.

Zachery 01-09-2005 05:32 AM

Quote:

Originally Posted by bkbelew
The post counts and what not dont matter to me. I do know that I have to get another license. After we run some tests on this one to make sure its not going to die we are going to purchase another.. probably monday morning.

Just as long as you are aware :)


All times are GMT. The time now is 12:20 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.01069 seconds
  • Memory Usage 1,758KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (7)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (19)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.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
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete