When a user creates an account he automaticcly gets an email with his username and password.
$msg = "Hello '$username'\nLogin Data:\n\nUsername: '$username'\nPassword: '$password'\n\nThank you for registering here!"; // Send mail $to = $email; $subject = "Welcome"; $headers = "From:mail@gmail.com\r\n"; mail($to, $subject, $msg, $headers); header("refresh:5;url=../index.html"); echo 'Registration successful. You\'ll be redirected in about 5 seconds. If not, click <a href="../index.html">here</a>.';
php.ini
SMTP = smtp.gmail.com
smtp_port = 25
sendmail_from = email@gmail.com
sendmail_path = "\"C:\xampp\sendmail\sendmail.exe\" -t"
sendmail_path="C:\xampp\mailtodisk\mailtodisk.exe"
sendmail.ini
smtp_server=smtp.gmail.com
smtp_port=25
error_logfile=error.log
debug_logfile=debug.log
auth_username=mail@gmail.com
auth_password=pass
force_sender=mail@gmail.com
Did I do something wrong ? :)