title: How integrate register users from main site throuth php? Vbulletin 5
body: <p>I have site <a href="http://example.com" rel="nofollow">http://example.com</a>. Forum located <a href="http://example.com/forum" rel="nofollow">http://example.com/forum</a>. 
  How can I call through api user registration. 
  My PHP code:</p>
  
  <pre><code>define('VB_ENTRY', 1);
  require_once(dirname(__FILE__) . '/../../forum/includes/api/interfaceabstract.php');
  require_once(dirname(__FILE__) . '/../../forum/includes/vb5/template/options.php');
  require_once(dirname(__FILE__) . '/../../forum/includes/vb5/cookie.php');
  require_once(dirname(__FILE__) . '/../../forum/includes/api/interface/collapsed.php');
  require_once(dirname(__FILE__) . '/../../forum/includes/api/interface/noncollapsed.php');
  require_once(dirname(__FILE__) . '/../../forum/includes/vb5/config.php');
  $config = vB5_Config::instance();
  
  $config-&gt;loadConfigFile('config.php');
  
  $api = Api_InterfaceAbstract::instance();
  print_r($rpassword1);
  $data = array(
      'userid'   =&gt; 0,
      'password' =&gt; $rpassword1,
      'user'     =&gt; array('username' =&gt; $ruser['user_name'], 'email' =&gt; $ruser['user_email']),
      array(),
      array(),
      'userfield' =&gt; false,
      array(),
      '',
      array('registration' =&gt; true),
  );
  // save data
  $response = $api-&gt;callApi('user', 'save', $data, false, true);
  </code></pre>
  
  <p>but it does not work.</p>