This should do what you want:
Hope this helps, -gjb-opendir(DIR, '.') || die("Can't open dir"); my @dirs = grep(/^\w/, readdir(DIR)); closedir(DIR); if (grep(/^$username$/, @dirs)) { print "yes\n"; }
In reply to Re: Does this user exist?
by gjb
in thread Does this user exist?
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |