vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Requests/Questions (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=112)
-   -   Membership Question - Please Help (https://vborg.vbsupport.ru/showthread.php?t=79351)

GregH 04-04-2005 06:30 PM

Membership Question - Please Help
 
I have a membership system set up for my website and I want to use the same member info in the forums. Can I pass a username and password to the foruml, so people are automatically logged in? Does anyone have altrernate suggestions on this?

TyleR 04-04-2005 07:09 PM

just require the backend file (you're global.php)...

so the top of the php page you have would look like this:

PHP Code:

// ####################### SET PHP ENVIRONMENT ###########################
error_reporting(E_ALL & ~E_NOTICE);

// #################### DEFINE IMPORTANT CONSTANTS #######################
define('THIS_SCRIPT''file_name_here');
define('NO_REGISTER_GLOBALS'1);

// ################### PRE-CACHE TEMPLATES AND DATA ######################
// get special phrase groups
$phrasegroups = array();

// get special data templates from the datastore
$specialtemplates = array();

// pre-cache templates used by all actions
$globaltemplates = array();

// pre-cache templates used by specific actions
$actiontemplates = array();

// ######################### REQUIRE BACK-END ############################
// assuming your forums folder is in a seperate direcotry than the area you have made.
require_once('../forum/global.php'); 


GregH 04-04-2005 07:23 PM

I am not following what I should do here, can you please elaborate a little more for me. I am new to using V-Bulletin software.

Thank You

TyleR 04-04-2005 07:28 PM

Alright..basically, you've got to define some variable so you dont catch any errors from your foums generic files:

PHP Code:

// ####################### SET PHP ENVIRONMENT ########################### 
error_reporting(E_ALL & ~E_NOTICE); 

// #################### DEFINE IMPORTANT CONSTANTS ####################### 
define('THIS_SCRIPT''file_name_here'); 
define('NO_REGISTER_GLOBALS'1); 

and change
PHP Code:

define('THIS_SCRIPT''file_name_here'); 

to the actual name of your file, minus the extension (.php, .php3, etc.).

now you'll need to cache the templates your forum uses (even if you dont want to use it), otherwise, you'll also get some errors.

PHP Code:

// ################### PRE-CACHE TEMPLATES AND DATA ###################### 
// get special phrase groups 
$phrasegroups = array(); 

// get special data templates from the datastore 
$specialtemplates = array(); 

// pre-cache templates used by all actions 
$globaltemplates = array(); 

// pre-cache templates used by specific actions 
$actiontemplates = array(); 

Then require your main file to make sure all sessions catch for this certain page and you don't get logged out:

PHP Code:

// ######################### REQUIRE BACK-END ############################ 
// assuming your forums folder is in a seperate direcotry than the area you have made. 
require_once('../forum/global.php'); 

hope this helps :)

GregH 04-04-2005 07:41 PM

Thanks, I'll try and see if I can figure this out.

CarterStClair 04-04-2005 08:47 PM

I'm confused...I have a user logged into the site using our own session variables. How does my site interact with the board using your method? You are giving instructions on how to include a file, right? But what about interfacing with the login system?

Thanks.

GregH 04-05-2005 12:07 PM

TanK DaWg
Anything on his comment/question?

Thanks

TyleR 04-05-2005 02:53 PM

two login systems that set different cookies won't interact 'friendly' per-say..once you enter the zone for one of the login-areas, the other will more than likely log you out thinking that the cookie is now gone (as it was now taken for the other login system...the one you are viewing)..it would be much wiser to just integrate vB's login with the current one you have.


All times are GMT. The time now is 05:49 PM.

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.01530 seconds
  • Memory Usage 1,734KB
  • 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
  • (5)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (8)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