feras
01-25-2009, 09:37 PM
so, I am looking to create a somewhat small system on my site, that involves the same users in the forums. Basically I want this features 'userbase' to be the same people in the forums.
Now, lets say my site is in the folder:
site
I also have a forums setup at site/forums/
which is where vbulletin is.
I'm trying to write a simple script in site, lets call this test.php, where it will also initialize the same session, and print that users ID if they're already logged into vbulletin.
I know lots about programming, but admit I don't know anywhere near enough about vbulletin, and if I can figure this part out the rest should be easy.
So again my test script is at:
site/test.php
Forums is at:
site/forums/
my test.php script I initially tried was
<?php
require_once('./forums/global.php');
print $vbulletin->session->vars['userid'];
?>
But that was giving me errors from global and init trying to do other includes at other paths that dont exist relevant to this path.
Any help is appreciated :)
Now, lets say my site is in the folder:
site
I also have a forums setup at site/forums/
which is where vbulletin is.
I'm trying to write a simple script in site, lets call this test.php, where it will also initialize the same session, and print that users ID if they're already logged into vbulletin.
I know lots about programming, but admit I don't know anywhere near enough about vbulletin, and if I can figure this part out the rest should be easy.
So again my test script is at:
site/test.php
Forums is at:
site/forums/
my test.php script I initially tried was
<?php
require_once('./forums/global.php');
print $vbulletin->session->vars['userid'];
?>
But that was giving me errors from global and init trying to do other includes at other paths that dont exist relevant to this path.
Any help is appreciated :)