PHP » PYTHON |
login |
register |
about
|
PYTHON posix_getpwnam
is this article helpful?
|
Python replacement for PHP's posix_getpwnam
[
edit
| history
]
import pwd pwd.getpwnam(username) posix_getpwnam(PHP 4, PHP 5) posix_getpwnam — Return info about a user by username Description
array posix_getpwnam
( string $username
)
Returns an array of information about the given user. Parameters
Return ValuesOn success an array with the following elements are returned, else FALSE is returned:
Examples
Example #1 Example use of posix_getpwnam()
<?php The above example will output something similar to: Array ( [name] => tom [passwd] => x [uid] => 10000 [gid] => 42 [geocs] => "tom,,," [dir] => "/home/tom" [shell] => "/bin/bash" )
|
more
Recently updated
more
Most requested
more
Last requests
|