Pulls account creation online FULLY.
Deletion is still not supported.
This commit is contained in:
@ -17,7 +17,43 @@ public class emailVerify {
|
||||
static final String senderPassword = "aotskDEVSIGNSERVICE32143214";
|
||||
static final String emailSMTPserver = "smtp.gmail.com";
|
||||
static final String emailSMTPPort = "465";
|
||||
public static void Onboarding(String receiverEmail) {
|
||||
//get date for email
|
||||
Date date = new Date();
|
||||
SimpleDateFormat formatter = new SimpleDateFormat("MM/dd/yy");
|
||||
String Date = formatter.format(date);
|
||||
//get time for sign in time
|
||||
Date dt = new Date();
|
||||
SimpleDateFormat dateFormat;
|
||||
dateFormat = new SimpleDateFormat("kk:mm:ss");
|
||||
|
||||
Properties props = new Properties();
|
||||
props.put("mail.smtp.host", emailSMTPserver);
|
||||
props.put("mail.smtp.socketFactory.port", emailSMTPPort);
|
||||
props.put("mail.smtp.socketFactory.class",
|
||||
"javax.net.ssl.SSLSocketFactory");
|
||||
props.put("mail.smtp.auth", "true");
|
||||
props.put("mail.smtp.port", emailSMTPPort);
|
||||
|
||||
try {
|
||||
Authenticator auth = new SMTPAuthenticator();
|
||||
Session session = Session.getInstance(props, auth);
|
||||
Message message = new MimeMessage(session);
|
||||
message.setFrom(new InternetAddress(senderEmailId));
|
||||
message.setRecipients(Message.RecipientType.TO,
|
||||
InternetAddress.parse(receiverEmail));
|
||||
message.setSubject("Welcome To Obsidian Core Studios!");
|
||||
message.setText("Seems You've Signed Up For An Account, We're Happy To have you here! \n \n \n \n \n " +
|
||||
"This Was Sent On Behalf Of Obsidian Core Studios By Our Super Cool Login Robots." +
|
||||
"\n You'll Only Get This Email Once (On-boarding Email).");
|
||||
|
||||
Transport.send(message);
|
||||
System.out.println("Sent Onboarding Email");
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
System.err.println("Email ONBOARD Not sent due to an error");
|
||||
}
|
||||
}
|
||||
public static void SendEmailThroughGmail(String receiverEmail, String User) {
|
||||
//get date for email
|
||||
Date date = new Date();
|
||||
|
Reference in New Issue
Block a user