The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
![]()
I have integrated VB in my website.
I imported all user to VB and use the VB login process whenever its necessary. My question is how do you check if a user is already logged in (outside the VB script scope)? Is there any VB API for that? Thanks, |
#2
|
|||
|
|||
![]()
First include global.php to load the vB environment, then check if $vbulletin->userinfo['userid'] > 0
|
#3
|
|||
|
|||
![]()
Thank you very much.
I tried that and I have a problem with it: The folder structure is like that web homepage web/forum VB I need to call the include in the "web" folder. When I do so I get an error: Warning: main(*****\web/includes/init.php): failed to open stream: No such file or directory in ****\web\forum\global.php on line 20 Is there an API interface for VB where I can get that info? On the same subject. Can I get from this array the user statistics. Meaning when he was last logged in, if he has unread private message, How many post he has. If not, where I can get that info. Thank you. |
#4
|
|||
|
|||
![]() Quote:
PHP Code:
Quote:
Quote:
|
#5
|
|||
|
|||
![]()
Unfortunately I get an error.
I created a test.php file. placed on the root folder. In that file: PHP Code:
Quote:
Any code samples ? Thanks, |
#6
|
|||
|
|||
![]() Quote:
Quote:
|
#7
|
|||
|
|||
![]() Quote:
Could be that the chdir() send output to the user side? |
#8
|
|||
|
|||
![]()
Try the following code, it should not give you any errors:
PHP Code:
|
#9
|
|||
|
|||
![]()
I think I found the problem.
Few days ago I was looking for a way to include a custom header using php include. I was told that the best way is to define a new plug-in and to call it on global_start. This is what I did PHP Code:
I am guessing that the ob_get_contents() causing this problem. So back to start. How do I include a php file not using this method. Thanks, anyone can help on this please ? |
#10
|
|||
|
|||
![]()
try this
PHP Code:
|
![]() |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|