Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- // Make a MySQL Connection
- mysql_connect("localhost", "root", "")
- or die(mysql_error());
- // Select Database
- mysql_select_db("dbusers")
- or die(mysql_error());
- // Insert values into table
- mysql_query("INSERT INTO users VALUES ( '$username', '$password', '$email' )");
- $username = $_post('username')
- $password = $_post('password')
- $email = $_post('email')
- //The web form for input ability
- {
- echo "<form action=\"register.php\" method=\"post\">\n";
- echo "Username: <input name=\"username\" MAXLENGTH=\"16\"><br />\n";
- echo "Password: <input type=\"password\" name=\"password\" MAXLENGTH=\"16\"><br />\n";
- echo "Email Address: <input name=\"email\" MAXLENGTH=\"25\"><br />\n";
- echo "<input type=\"submit\">\n";
- echo "</form>\n";
- }
- // EOF
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement