Lunarpages Web Hosting Forum

Author Topic: Email Form 501:SMTP server error  (Read 4511 times)

Offline staticfiends.com

  • Spacescooter Operator
  • *****
  • Posts: 32
    • http://www.staticfiends.com
Email Form 501:SMTP server error
« on: July 28, 2002, 07:37:00 AM »
I have reformatted my ASP email form to fit to chilisoft system
(CDONTS), but it continues to give me the same error:

~~~~~ Error encountered: 501:SMTP server error ~~~~~

here is my current script:
 
 

code:
 <%
Set mailmsg = Server.CreateObject("CDONTS.NewMail")

mailmsg.To = "webmaster@staticfiends.com"

mailmsg.From = request.form("Name") ' Specify sender's name

mailmsg.Body = "Peaceful Productions Request" & Chr(13) & Chr(10) & Chr(13) & Chr(10) & _
"Email: " & request.form("Email") & Chr(13) & Chr(10) & _
"Comments: " & request.form("comments") & Chr(13) & Chr(10)

mailmsg.Host = "neptune.lunarpages.com" ' Specify a valid SMTP server



On Error Resume Next
mailmsg.Send
If Err <> 0 Then
Response.Write "Error encountered: " & Err.Description
else
response.write "Thank you. We will contact you shortly,about your request."
response.redirect("/peaceful-productions/index.htm")
End If
%>


through suggestions from the chilisoft help forum, I have tried these
alternatives:

mailmsg.Host = "66.28.237.139"
mailmsg.Host = "localhost"

none of these work (all returning the same error)
 

Any suggestions or help??

thanks

fd
staticfiend.com

Offline Max

  • Über Jedi
  • *****
  • Posts: 2506
    • Max's website!
Email Form 501:SMTP server error
« Reply #1 on: July 28, 2002, 07:50:00 PM »
This is an example of a CDONTS script that works:

 
code:
  <% Option Explicit

        Dim strEmail, strName, item
        strEmail = trim(Request("Email_Address"))
        strName = Trim(Request("Contact_Name"))

        If Len(strEmail) < 1 Then
                Response.Write "Error: No Email given"
                Response.End
        End if

        Dim objCDO
        'Set objCDO = CreateObject("CDONTS.NewMail")


        'objCDO.To = "max@lunarpages.com (A N Varma)"
        'objCDO.From = strEmail & " (" & strName & ")"

        'objCDO.Subject = Trim(Request("Subject"))

        For Each item in Request.Form
                Response.Write item & " = " & Request.Form(item) & "<BR>"
        Next
        'objCDO.Importance = 2 'High importance!

        'objCDO.Send 'Send off the email!

'Cleanup
Set objCDO = Nothing



%>

It has to be run twice when you first try it, so it gets registered by the asp engine.

Offline staticfiends.com

  • Spacescooter Operator
  • *****
  • Posts: 32
    • http://www.staticfiends.com
Email Form 501:SMTP server error
« Reply #2 on: July 29, 2002, 06:40:00 AM »
So how would I go about fitting this for chilisoft?  

the script I put in the above post is basically from a chilisoft example that they give on their site...so I figured it would work just fine....in the help forum they asked to me change the mailmsg.Host around when I began getting the 501 error...I did, but it didn't work...then they thought it was my host.....   "[brows]"  

I am a bit frustrated, but once it finally works, it will all be worth it...until then...this sucks!        "[lighting]"
 
 [ July 31, 2002, 02:18 AM: Message edited by: staticfiends.com ]

Offline staticfiends.com

  • Spacescooter Operator
  • *****
  • Posts: 32
    • http://www.staticfiends.com
Email Form 501:SMTP server error
« Reply #3 on: August 03, 2002, 06:45:00 AM »
The people at chilisoft suggest I do this, but I don't know how:

 
code:
From a shell prompt on the Linux box, do the following:

telnet localhost 25

does it connect? if so, type the following (note the exact syntax, the dots, semi-colons)

helo there
mail from: email@address <--- value from your ASP script (From)
rcpt to: email@address <--- value from your ASP script (To)
data
Subject: test message
this is a test
.
quit