Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- if ($_POST['go']) {
- $username = $_POST['txt']; $email_address = "ani@ba.com";
- $password = "12345678"; $group_id = 2; $user_type = USER_NORMAL;
- include "forum/includes/functions_user.php";
- $user_row = array(
- 'username' => $username,
- 'user_password' => phpbb_hash($password),
- 'user_email' => $email_address,
- 'group_id' => (int) $group_id,
- 'user_timezone' => (float) $timezone,
- 'user_dst' => $is_dst,
- 'user_lang' => $language,
- 'user_type' => $user_type,
- 'user_actkey' => $user_actkey,
- 'user_ip' => $user_ip,
- 'user_regdate' => $registration_time,
- 'user_inactive_reason' => $user_inactive_reason,
- 'user_inactive_time' => $user_inactive_time,
- );
- // all the information has been compiled, add the user
- // tables affected: users table, profile_fields_data table, groups table, and config table.
- $user_id = user_add($user_row);
- echo "user: $user_id";
- }
- echo "
- <form action='".$_SERVER['PHP_SELF']."' method='POST'>
- <input type=text name=txt><input type=submit name=go>
- </form>
- ";
- ?>
Add Comment
Please, Sign In to add comment