The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Add User Script in PHP
Hello,
Can someone guide me how to write a PHP script (for vBulletin 4.2.2) that adds a user. No verification of user required, just add the user. Thanks for your help, Peter |
#2
|
||||
|
||||
Did you check the articles forum? There is an article somewhere in there on adding users.
|
#3
|
|||
|
|||
This should get you started.
As @Lynne suggested you should search yourself for a more comprehensive search. http://www.vbulletin.com/forum/forum...emote-location https://vborg.vbsupport.ru/showthread.php?t=82836 |
Благодарность от: | ||
Lynne |
#4
|
|||
|
|||
Thank you Lynne and tbworld. I did see thread 82836, but was unable to run it successfully. SInce it was an old thread and I am running 4.2.2 I raised this again.
It did succeed now: I placed this script in the root directory of my vbulletin tree and it now did run, both from a url call as well as from the command line. Thanks for your patience and help. Peter <?php define('VB_AREA', 'External'); define('SKIP_SESSIONCREATE', 1); define('SKIP_USERINFO', 1); define('CWD', '/pathtomyvbulletin'); require_once(CWD . '/includes/init.php'); $newuser =& datamanager_init('User', $vbulletin, ERRTYPE_ARRAY); $newuser->set('username', 'Auto User'); $newuser->set('email', 'myuser@email.com'); $newuser->set('password', 'verysecret'); $newuser->set('usergroupid', 2); $newuserid = $newuser->save(); ?> |
Благодарность от: | ||
tbworld |
#5
|
||||
|
||||
Did you go to the very last page of the thread to see users posting scripts that work with vB4.x?
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|