hello Mr. Thomas,
 
 thanks for the quick reply. i implimented your code. let me know what's wrong with my 
code.
 
newuser.htm:
html
head
body
form action = "signup.php" method = post
Username: input type = text size = 30 name = "USERNAME"
Password: input type = password size = 30 name = "PASSWORD"
Confirm: input type = password size = 30 name = "VERIFYPASSWORD"

input type = submit value = "Sign Up"
/form
/body
/html

 
signup.php
<?php
IF ($_POST[PASSWORD] == $_POST[VERIFYPASSWORD]){
 exec("/usr/sbin/useradd -p $_POST[PASSWORD] $_POST[USERNAME]");

}
else
{
 Print("<b> Passwords did not match");
}
?>

 
can u suggest me.?
 
 
thanks,
Kumar.
 


Thomas <[EMAIL PROTECTED]> wrote:
Try checking out the exec() function
http://us4.php.net/manual/en/function.exec.php

Should start out with 3 input boxes.
USERNAME
PASSWORD
VERIFYPASSWORD

IF ($_POST/GET[PASSWORD] == $_POST/GET[VERIFYPASSWORD]){

exec("/path/to/useradd -p $_POST/GET[PASSWORD]
$_POST/GET[USERNAME]");

}

The above is assuming you are executing exec() functions as a PRIVILEGED
user. It also assumes that no one is able to view the processes taking
place on the machine as the password will show up in clear text when
ps'n (reporting process status). This also assumes you are not running
IIS on a windows platform.

The above is just an example (and a crappy one at that), I am not
responsible for ANYTHING you do with this.

These "assumptions" may help. Read below.
_________________
MOST IMPORTANTLY
ŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻ
1. READ POSTING RULES
2. hmm, it's in the posting rules.
3. http://us4.php.net/mailing-lists.php
4. Do not reply to my email address.


-----Original Message-----
From: Rajendra Kumar [mailto:[EMAIL PROTECTED] 
Sent: Friday, July 18, 2003 3:02 AM
To: [EMAIL PROTECTED]
Subject: [PHP-INST] New User Creation.


Hello List,

i am new to php programming. can anyone help me to create a linux
user using php program and also i want to assign passwd to the new
created user. just like New User Sign Up form for an email. i use
squirrel mail they din't provided the new user sign up.

any help will be appreciated.

thank,
Kumar.

Catch all the cricket action. Download Yahoo! Score tracker



--
PHP Install Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Catch all the cricket action. Download Yahoo! Score tracker

Reply via email to