File_Passwd_Smb::addUser()

File_Passwd_Smb::addUser() -- Add an user

Synopsis

mixed File_Passwd_Smb::addUser (string $user, string $pass, array $params [, boolean $isMachine = false])

Opis

Add an SMB user/machine account.

Parametr

string $user

the user/machine to add

string $pass

the new plaintext password

array $params

additional properties of account:

  • userid

  • flags

  • lct

  • comment

boolean $isMachine

whether to add an machine account

Zwracana wartość

Zwraca TRUE w przypadku powodzenia, PEAR_Error w przypadku niepowodzenia.

Tabela 39-1. Możliwe wartości PEAR_Error

Error CodeSummary
FILE_PASSWD_E_EXISTS_ALREADYaccount already exists
FILE_PASSWD_E_INVALID_CHARSuser/machine name contains illegal characters

Uwagi

Ta funkcja nie może być wywołana statycznie.