View Single Post
  #6  
Old 13 Feb 2015, 17:25
Dead Eddie's Avatar
Dead Eddie Dead Eddie is offline
 
Join Date: Apr 2004
Originally Posted by cnnx View Post
So I found this on the forum, which I modified a bit for VB5.

define('VB_AREA', 'External');
define('SKIP_SESSIONCREATE', 1);
define('SKIP_USERINFO', 1);
define('CWD', 'forum');
require_once(CWD . '/core/includes/init.php');

$newuser =& datamanager_init('User', $vbulletin, ERRTYPE_ARRAY);
$newuser->set('username', '$user');
$newuser->set('email', '$email');
$newuser->set('password', '$pass');
$newuser->set('usergroupid', 2);

$user,$email,$pass are my variables on my website for when a new user signs up, what do I need to modify to make it vb5 compatible? as this was for vb3/vb4.. ?
Vb5 doesn't use the data managers, so that's not going to work.

I'm doing something similar for somebody as a POC, so I'll be posting sample code. Otherwise, you'll have to look into how to actually call the API (either internally or externally, depending on your need).
Reply With Quote