I wonder if I can send an email via smtp using Gmail account without installing a mail server or not?
For example:
re_pass.asp
<p>Password Reminder</p>
<form method="post" action="re_pass_process.asp">
<input type="text" name="email">
<input type="submit" value="Send">
</form>
re_pass_process.asp
<!--#include file="connection.asp"-->
<%
openConn()
email = request("email")
response.Write(email)
''response.End()
if trim(email) <> "" then
sql= "select password from candidate where email = '" & replace(email,"'","''") & "'"
''response.Write(sql)
''response.End()
set rs = createobject("adodb.recordset")
rs.open sql,conn
''response.End()
if not rs.eof then
set msg = createobject("CDO.Message")
msg.to = email
''response.Write(email)
msg.from = "tranlinh.nmt@gmail.com"
msg.subject = "123456" ' pass for mail:tranlinh.nmt@gmail.com
msg.TextBody = "Hello. Your password is " & rs("password")
response.Write rs("password")
''response.End()
msg.Send
response.End()
end if
rs.close
end if
%>
As above, what need to be installed to send an email?