In a very very basic way:
db table users
------------------
user_id (prim. key auto inc)
username
password
<?php
/* Create an HTML form with two fields, named username and
password. Point the form action at a PHP file containing a function
similar to this */
function addUser(){
$sql = "INSERT INTO users VALUES (null, '".$_POST['username']."', '".$_POST['password']."' )";
mysql_query($query);
echo "accepted new user details: ".mysql_insert_id().", ".$_POST['username'].", ".$_POST['password'];
exit;
}
?>
You would want to flesh out the above to make it do want you want to do.