By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
428,838 Members | 2,222 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 428,838 IT Pros & Developers. It's quick & easy.

CDONTS.Send w URL in Body

P: n/a
Hi,

I have a page that sends user comments with CDONTS, works fine.
Until I put a URL (http://192.168.0.1).
If I use http://domain.com it works fine.

Why with the numeric URL, CDONTS does not send the mail??

Thanks

Mario
Jul 19 '05 #1
Share this Question
Share on Google+
7 Replies


P: n/a
Is that really all that's different? Can you show your code? Any SMTP
events in any event logs on the server? And bad mail in the badmail
directory? Are you on an NT server? If not, have you tried using CDO
instead of CDONTS?

Ray at work

"Mario Leduc" <ml****@ncc-ccn.ca> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
Hi,

I have a page that sends user comments with CDONTS, works fine.
Until I put a URL (http://192.168.0.1).
If I use http://domain.com it works fine.

Why with the numeric URL, CDONTS does not send the mail??

Thanks

Mario

Jul 19 '05 #2

P: n/a
Here is the code
Dim rqEmail, rqSubject, rqBody, interface
rqEmail = Request.Form("email")
rqSubject = Request.Form("subject")
rqBody = Request.Form("body")
rqInterface = Request.Form("interface")

rqBody = rqBody & vbCRLF & vbCRLF & vbCRLF & "<site1>"

Dim objMail
Set objMail = CreateObject("CDONTS.NewMail")

objMail.From = rqEmail
objMail.To = "em***@domain.com"
objMail.Subject = rqSubject
objMail.MailFormat = 1
objMail.BodyFormat = 1
objMail.Body = rqBody

On error resume next
objMail.Send
Set objMail = nothing

If rqInterface = "2" Then
Response.Redirect("/contactus/thanks_f.asp")
Else
Response.Redirect("/contactus/thanks_e.asp")
End If

Whats the diference between CDO and CDONTS anyway?

Thanks

"Ray at <%=sLocation%>" <myfirstname at lane34 dot com> wrote in message
news:%2***************@TK2MSFTNGP10.phx.gbl...
Is that really all that's different? Can you show your code? Any SMTP
events in any event logs on the server? And bad mail in the badmail
directory? Are you on an NT server? If not, have you tried using CDO
instead of CDONTS?

Ray at work

"Mario Leduc" <ml****@ncc-ccn.ca> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
Hi,

I have a page that sends user comments with CDONTS, works fine.
Until I put a URL (http://192.168.0.1).
If I use http://domain.com it works fine.

Why with the numeric URL, CDONTS does not send the mail??

Thanks

Mario


Jul 19 '05 #3

P: n/a
Where does the IP address come from?

Try this modified version for debugging purposes:
Dim rqEmail, rqSubject, rqBody, interface
rqEmail = Request.Form("email")
rqSubject = Request.Form("subject")
rqBody = Request.Form("body")
rqInterface = Request.Form("interface")

rqBody = rqBody & vbCRLF & vbCRLF & vbCRLF & "<site1>"

RESPONSE.WRITE "EMAIL: " & rqEmail & "<hr>"
RESPONSE.WRITE "SUBJECT: " & rsSubject & "<hr>"
RESPONSE.WRITE "BODY: " & rqBody & "<hr>"
Dim objMail
Set objMail = CreateObject("CDONTS.NewMail")

objMail.From = rqEmail
objMail.To = "em***@domain.com"
objMail.Subject = rqSubject
objMail.MailFormat = 1
objMail.BodyFormat = 1
objMail.Body = rqBody

'' On error resume next THIS IS COMMENTED OUT, SINCE YOU'RE DEBUGGING...
objMail.Send
Set objMail = nothing

RESPONSE.END

If rqInterface = "2" Then
Response.Redirect("/contactus/thanks_f.asp")
Else
Response.Redirect("/contactus/thanks_e.asp")
End If
What's rq?
Whats the diference between CDO and CDONTS anyway?


CDONTS = old technology
CDO = new technology

See here:
http://www.aspfaq.com/show.asp?id=2026
And if you miss the link, also see here:
http://support.microsoft.com/?kbid=810702

Ray at work








Jul 19 '05 #4

P: n/a
I converted to CDO still not working when I put something like this in the
body
http://192.168.0.2/

but if I put http://www.domain.com/ it worked?

Here is the code

Dim rqEmail, rqSubject, rqBody, interface
rqEmail = Request.Form("email")
rqSubject = Request.Form("subject")
rqBody = Request.Form("body")
rqInterface = Request.Form("interface")

rqBody = rqBody & vbCRLF & vbCRLF & vbCRLF & "<site1>"

Response.Write "Email = " & rqEmail & "<BR>"
Response.Write "Subject = " & rqSubject & "<BR>"
Response.Write "Body = " & rqBody & "<BR>"

Dim cdoMessage
Set cdoMessage = CreateObject("CDO.Message")

With cdoMessage
.From = rqEmail
.To = "ml****@ncc-ccn.ca"
.Subject = rqSubject
.TextBody = rqBody
.Send
End With

Set cdoMessage = Nothing

rq stands for request
only for differentiate from body


"Ray at <%=sLocation%>" <myfirstname at lane34 dot com> wrote in message
news:%2****************@TK2MSFTNGP12.phx.gbl...
Where does the IP address come from?

Try this modified version for debugging purposes:
Dim rqEmail, rqSubject, rqBody, interface
rqEmail = Request.Form("email")
rqSubject = Request.Form("subject")
rqBody = Request.Form("body")
rqInterface = Request.Form("interface")

rqBody = rqBody & vbCRLF & vbCRLF & vbCRLF & "<site1>"

RESPONSE.WRITE "EMAIL: " & rqEmail & "<hr>"
RESPONSE.WRITE "SUBJECT: " & rsSubject & "<hr>"
RESPONSE.WRITE "BODY: " & rqBody & "<hr>"
Dim objMail
Set objMail = CreateObject("CDONTS.NewMail")

objMail.From = rqEmail
objMail.To = "em***@domain.com"
objMail.Subject = rqSubject
objMail.MailFormat = 1
objMail.BodyFormat = 1
objMail.Body = rqBody

'' On error resume next THIS IS COMMENTED OUT, SINCE YOU'RE DEBUGGING...
objMail.Send
Set objMail = nothing

RESPONSE.END

If rqInterface = "2" Then
Response.Redirect("/contactus/thanks_f.asp")
Else
Response.Redirect("/contactus/thanks_e.asp")
End If
What's rq?
Whats the diference between CDO and CDONTS anyway?


CDONTS = old technology
CDO = new technology

See here:
http://www.aspfaq.com/show.asp?id=2026
And if you miss the link, also see here:
http://support.microsoft.com/?kbid=810702

Ray at work








Jul 19 '05 #5

P: n/a
Any SMTP
events in any event logs on the server? And bad mail in the badmail
directory?

Try this modified version for debugging purposes:
Dim rqEmail, rqSubject, rqBody, interface
rqEmail = Request.Form("email")
rqSubject = Request.Form("subject")
rqBody = Request.Form("body")
rqInterface = Request.Form("interface")

rqBody = rqBody & vbCRLF & vbCRLF & vbCRLF & "<site1>"

RESPONSE.WRITE "EMAIL: " & rqEmail & "<hr>"
RESPONSE.WRITE "SUBJECT: " & rsSubject & "<hr>"
RESPONSE.WRITE "BODY: " & rqBody & "<hr>"
Dim objMail
Set objMail = CreateObject("CDO.Message")

objMail.From = rqEmail
objMail.To = "em***@domain.com"
objMail.Subject = rqSubject
objMail.TextyBody = rqBody

'' On error resume next THIS IS COMMENTED OUT, SINCE YOU'RE DEBUGGING...
objMail.Send
Set objMail = nothing

RESPONSE.END

"Mario Leduc" <ml****@ncc-ccn.ca> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
I converted to CDO still not working when I put something like this in the
body
http://192.168.0.2/

but if I put http://www.domain.com/ it worked?

Here is the code

Dim rqEmail, rqSubject, rqBody, interface
rqEmail = Request.Form("email")
rqSubject = Request.Form("subject")
rqBody = Request.Form("body")
rqInterface = Request.Form("interface")

rqBody = rqBody & vbCRLF & vbCRLF & vbCRLF & "<site1>"

Response.Write "Email = " & rqEmail & "<BR>"
Response.Write "Subject = " & rqSubject & "<BR>"
Response.Write "Body = " & rqBody & "<BR>"

Dim cdoMessage
Set cdoMessage = CreateObject("CDO.Message")

With cdoMessage
.From = rqEmail
.To = "ml****@ncc-ccn.ca"
.Subject = rqSubject
.TextBody = rqBody
.Send
End With

Set cdoMessage = Nothing

rq stands for request
only for differentiate from body


"Ray at <%=sLocation%>" <myfirstname at lane34 dot com> wrote in message
news:%2****************@TK2MSFTNGP12.phx.gbl...
Where does the IP address come from?

Try this modified version for debugging purposes:
Dim rqEmail, rqSubject, rqBody, interface
rqEmail = Request.Form("email")
rqSubject = Request.Form("subject")
rqBody = Request.Form("body")
rqInterface = Request.Form("interface")

rqBody = rqBody & vbCRLF & vbCRLF & vbCRLF & "<site1>"

RESPONSE.WRITE "EMAIL: " & rqEmail & "<hr>"
RESPONSE.WRITE "SUBJECT: " & rsSubject & "<hr>"
RESPONSE.WRITE "BODY: " & rqBody & "<hr>"
Dim objMail
Set objMail = CreateObject("CDONTS.NewMail")

objMail.From = rqEmail
objMail.To = "em***@domain.com"
objMail.Subject = rqSubject
objMail.MailFormat = 1
objMail.BodyFormat = 1
objMail.Body = rqBody

'' On error resume next THIS IS COMMENTED OUT, SINCE YOU'RE DEBUGGING... objMail.Send
Set objMail = nothing

RESPONSE.END

If rqInterface = "2" Then
Response.Redirect("/contactus/thanks_f.asp")
Else
Response.Redirect("/contactus/thanks_e.asp")
End If
What's rq?
Whats the diference between CDO and CDONTS anyway?


CDONTS = old technology
CDO = new technology

See here:
http://www.aspfaq.com/show.asp?id=2026
And if you miss the link, also see here:
http://support.microsoft.com/?kbid=810702

Ray at work









Jul 19 '05 #6

P: n/a
SMTP event log does not contains any error nor that any badmail in the bad
mail folder

Tried your debug code, can see the body with the http://192.168.0.1/ in the
response.write, but the mail was not sent??

If I put 192.168.0.1 without the http:// it worked??

Is it a bug of CDO??
"Ray at <%=sLocation%>" <myfirstname at lane34 dot com> wrote in message
news:uM**************@TK2MSFTNGP12.phx.gbl...
Any SMTP
events in any event logs on the server? And bad mail in the badmail
directory?

Try this modified version for debugging purposes:
Dim rqEmail, rqSubject, rqBody, interface
rqEmail = Request.Form("email")
rqSubject = Request.Form("subject")
rqBody = Request.Form("body")
rqInterface = Request.Form("interface")

rqBody = rqBody & vbCRLF & vbCRLF & vbCRLF & "<site1>"

RESPONSE.WRITE "EMAIL: " & rqEmail & "<hr>"
RESPONSE.WRITE "SUBJECT: " & rsSubject & "<hr>"
RESPONSE.WRITE "BODY: " & rqBody & "<hr>"
Dim objMail
Set objMail = CreateObject("CDO.Message")

objMail.From = rqEmail
objMail.To = "em***@domain.com"
objMail.Subject = rqSubject
objMail.TextyBody = rqBody

'' On error resume next THIS IS COMMENTED OUT, SINCE YOU'RE DEBUGGING...
objMail.Send
Set objMail = nothing

RESPONSE.END

"Mario Leduc" <ml****@ncc-ccn.ca> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
I converted to CDO still not working when I put something like this in the
body
http://192.168.0.2/

but if I put http://www.domain.com/ it worked?

Here is the code

Dim rqEmail, rqSubject, rqBody, interface
rqEmail = Request.Form("email")
rqSubject = Request.Form("subject")
rqBody = Request.Form("body")
rqInterface = Request.Form("interface")

rqBody = rqBody & vbCRLF & vbCRLF & vbCRLF & "<site1>"

Response.Write "Email = " & rqEmail & "<BR>"
Response.Write "Subject = " & rqSubject & "<BR>"
Response.Write "Body = " & rqBody & "<BR>"

Dim cdoMessage
Set cdoMessage = CreateObject("CDO.Message")

With cdoMessage
.From = rqEmail
.To = "ml****@ncc-ccn.ca"
.Subject = rqSubject
.TextBody = rqBody
.Send
End With

Set cdoMessage = Nothing

rq stands for request
only for differentiate from body


"Ray at <%=sLocation%>" <myfirstname at lane34 dot com> wrote in message
news:%2****************@TK2MSFTNGP12.phx.gbl...
Where does the IP address come from?

Try this modified version for debugging purposes:
Dim rqEmail, rqSubject, rqBody, interface
rqEmail = Request.Form("email")
rqSubject = Request.Form("subject")
rqBody = Request.Form("body")
rqInterface = Request.Form("interface")

rqBody = rqBody & vbCRLF & vbCRLF & vbCRLF & "<site1>"

RESPONSE.WRITE "EMAIL: " & rqEmail & "<hr>"
RESPONSE.WRITE "SUBJECT: " & rsSubject & "<hr>"
RESPONSE.WRITE "BODY: " & rqBody & "<hr>"
Dim objMail
Set objMail = CreateObject("CDONTS.NewMail")

objMail.From = rqEmail
objMail.To = "em***@domain.com"
objMail.Subject = rqSubject
objMail.MailFormat = 1
objMail.BodyFormat = 1
objMail.Body = rqBody

'' On error resume next THIS IS COMMENTED OUT, SINCE YOU'RE

DEBUGGING... objMail.Send
Set objMail = nothing

RESPONSE.END

If rqInterface = "2" Then
Response.Redirect("/contactus/thanks_f.asp")
Else
Response.Redirect("/contactus/thanks_e.asp")
End If
What's rq?

> Whats the diference between CDO and CDONTS anyway?

CDONTS = old technology
CDO = new technology

See here:
http://www.aspfaq.com/show.asp?id=2026
And if you miss the link, also see here:
http://support.microsoft.com/?kbid=810702

Ray at work










Jul 19 '05 #7

P: n/a
Is the mail in the pickup directory or the queue directory? I suppose it
could be a bug.

Ray at work

"Mario Leduc" <ml****@ncc-ccn.ca> wrote in message
news:et*************@TK2MSFTNGP12.phx.gbl...
SMTP event log does not contains any error nor that any badmail in the bad
mail folder

Tried your debug code, can see the body with the http://192.168.0.1/ in the response.write, but the mail was not sent??

If I put 192.168.0.1 without the http:// it worked??

Is it a bug of CDO??
"Ray at <%=sLocation%>" <myfirstname at lane34 dot com> wrote in message
news:uM**************@TK2MSFTNGP12.phx.gbl...
Any SMTP
events in any event logs on the server? And bad mail in the badmail
directory?

Try this modified version for debugging purposes:
Dim rqEmail, rqSubject, rqBody, interface
rqEmail = Request.Form("email")
rqSubject = Request.Form("subject")
rqBody = Request.Form("body")
rqInterface = Request.Form("interface")

rqBody = rqBody & vbCRLF & vbCRLF & vbCRLF & "<site1>"

RESPONSE.WRITE "EMAIL: " & rqEmail & "<hr>"
RESPONSE.WRITE "SUBJECT: " & rsSubject & "<hr>"
RESPONSE.WRITE "BODY: " & rqBody & "<hr>"
Dim objMail
Set objMail = CreateObject("CDO.Message")

objMail.From = rqEmail
objMail.To = "em***@domain.com"
objMail.Subject = rqSubject
objMail.TextyBody = rqBody

'' On error resume next THIS IS COMMENTED OUT, SINCE YOU'RE DEBUGGING...
objMail.Send
Set objMail = nothing

RESPONSE.END

"Mario Leduc" <ml****@ncc-ccn.ca> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
I converted to CDO still not working when I put something like this in

the body
http://192.168.0.2/

but if I put http://www.domain.com/ it worked?

Here is the code

Dim rqEmail, rqSubject, rqBody, interface
rqEmail = Request.Form("email")
rqSubject = Request.Form("subject")
rqBody = Request.Form("body")
rqInterface = Request.Form("interface")

rqBody = rqBody & vbCRLF & vbCRLF & vbCRLF & "<site1>"

Response.Write "Email = " & rqEmail & "<BR>"
Response.Write "Subject = " & rqSubject & "<BR>"
Response.Write "Body = " & rqBody & "<BR>"

Dim cdoMessage
Set cdoMessage = CreateObject("CDO.Message")

With cdoMessage
.From = rqEmail
.To = "ml****@ncc-ccn.ca"
.Subject = rqSubject
.TextBody = rqBody
.Send
End With

Set cdoMessage = Nothing

rq stands for request
only for differentiate from body


"Ray at <%=sLocation%>" <myfirstname at lane34 dot com> wrote in message news:%2****************@TK2MSFTNGP12.phx.gbl...
> Where does the IP address come from?
>
>
>
> Try this modified version for debugging purposes:
>
>
> Dim rqEmail, rqSubject, rqBody, interface
> rqEmail = Request.Form("email")
> rqSubject = Request.Form("subject")
> rqBody = Request.Form("body")
> rqInterface = Request.Form("interface")
>
> rqBody = rqBody & vbCRLF & vbCRLF & vbCRLF & "<site1>"
>
> RESPONSE.WRITE "EMAIL: " & rqEmail & "<hr>"
> RESPONSE.WRITE "SUBJECT: " & rsSubject & "<hr>"
> RESPONSE.WRITE "BODY: " & rqBody & "<hr>"
>
>
> Dim objMail
> Set objMail = CreateObject("CDONTS.NewMail")
>
> objMail.From = rqEmail
> objMail.To = "em***@domain.com"
> objMail.Subject = rqSubject
> objMail.MailFormat = 1
> objMail.BodyFormat = 1
> objMail.Body = rqBody
>
> '' On error resume next THIS IS COMMENTED OUT, SINCE YOU'RE

DEBUGGING...
> objMail.Send
> Set objMail = nothing
>
> RESPONSE.END
>
> If rqInterface = "2" Then
> Response.Redirect("/contactus/thanks_f.asp")
> Else
> Response.Redirect("/contactus/thanks_e.asp")
> End If
>
>
> What's rq?
>
> > Whats the diference between CDO and CDONTS anyway?
>
> CDONTS = old technology
> CDO = new technology
>
> See here:
> http://www.aspfaq.com/show.asp?id=2026
> And if you miss the link, also see here:
> http://support.microsoft.com/?kbid=810702
>
> Ray at work
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>



Jul 19 '05 #8

This discussion thread is closed

Replies have been disabled for this discussion.