Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <form action="script.php" method="post">
- <input type="text" name="username" value="$username" />
- <input type="text" name="password" value="$password" />
- <input type="submit" name="submit" />
- </form>
- <?php
- require_once("mysql.php");
- if (!empty($_POST['username']) && !empty($_POST['password']) {
- $username = $_POST['username'];
- $password = $_POST['password'];
- mysql_query("INSERT into USERS (username,password) VALUES ('$username', '$password')");
- }
- else "Go back and fill out the form.";
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement