Re: TCP Connect code for SMTP transaction
This WebDNA talk-list message is from 2004
It keeps the original formatting.
numero = 57627
interpreted = N
texte = Colin Sidwell wrote:> The emailer application in OSX is too primitive, e.g. unless you look in the> log or problem email folder, you don't know if your message bounced.The [sendmail] context is only intended to connect to a real e-mail server, which will then handle the queuing of the messages for eventual delivery. It is not intended to be used to directly send messages. If you are not familiar with how to use the OSX SMTP server (which should be sendmail itself if I am not mistaken), perhaps you should learn to use the system tool correctly, rather than trying to hack up something poor.Bounced messages will be reported to the envelope FROM: address; if this isn't a real mailbox, you won't get bounce messages. If you are concerned about people typing in a non-working e-mail address, you can do ask them to key it in twice (this usually gets them to think before they type). Or if you are dealing with a high-value transaction, you e-mail them a link to continue the transaction, rather than completing the transaction with the initial e-mail. You can also do some simple validation of the e-mail address using either JavaScript or the [grep] context.> > I am experimenting with writing my own, here's what I've got so far-> > [TCPConnect host=[server]&port=25]> [TCPSend end=%0D%0A]HELO [hello][UnURL]%0D%0A[/UnURL][/TCPSend]> [TCPSend end=%0D%0A]MAIL FROM:[from][UnURL]%0D%0A[/UnURL][/TCPSend]> [TCPSend end=%0D%0A]RCPT TO:[to][UnURL]%0D%0A[/UnURL][/TCPSend]> [TCPSend end=%0D%0A]DATA[UnURL]%0D%0A[/UnURL][/TCPSend]> [TCPSend end=%0D%0A]X-Mailer: Ideal TCP ConnectorThis won't work in general, as I said, since you have no way of waiting for the prompts from the remote server. A SMTP transaction is a conversation between two systems; the SMTP software I use would cut your code off because you start "talking" before I have answered your initial greeting.The biggest mistake people make when posting questions to a list is to describe what they [think they] need to do, rather than describe what they actually want to accomplish. You've already decided you need a SMTP client, when the problem you are trying to solve is something completely different...John-- John PeacockDirector of Information Research and TechnologyRowman & Littlefield Publishing Group4501 Forbes BoulevardSuite HLanham, MD 20706301-459-3366 x.5010fax 301-429-5748-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list
.To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/
Associated Messages, from the most recent to the oldest:
Colin Sidwell wrote:> The emailer application in OSX is too primitive, e.g. unless you look in the> log or problem email folder, you don't know if your message bounced.The [sendmail] context is only intended to connect to a real e-mail server, which will then handle the queuing of the messages for eventual delivery. It is not intended to be used to directly send messages. If you are not familiar with how to use the OSX SMTP server (which should be sendmail itself if I am not mistaken), perhaps you should learn to use the system tool correctly, rather than trying to hack up something poor.Bounced messages will be reported to the envelope FROM: address; if this isn't a real mailbox, you won't get bounce messages. If you are concerned about people typing in a non-working e-mail address, you can do ask them to key it in twice (this usually gets them to think before they type). Or if you are dealing with a high-value transaction, you e-mail them a link to continue the transaction, rather than completing the transaction with the initial e-mail. You can also do some simple validation of the e-mail address using either JavaScript or the [grep] context.> > I am experimenting with writing my own, here's what I've got so far-> > [TCPConnect host=[server]&port=25]> [TCPSend end=%0D%0A]HELO [hello][unurl]%0D%0A[/UnURL][/TCPSend]> [TCPSend end=%0D%0A]MAIL FROM:[from][unurl]%0D%0A[/UnURL][/TCPSend]> [TCPSend end=%0D%0A]RCPT TO:[to][unurl]%0D%0A[/UnURL][/TCPSend]> [TCPSend end=%0D%0A]DATA[unurl]%0D%0A[/UnURL][/TCPSend]> [TCPSend end=%0D%0A]X-Mailer: Ideal TCP ConnectorThis won't work in general, as I said, since you have no way of waiting for the prompts from the remote server. A SMTP transaction is a conversation between two systems; the SMTP software I use would cut your code off because you start "talking" before I have answered your initial greeting.The biggest mistake people make when posting questions to a list is to describe what they [think they] need to do, rather than describe what they actually want to accomplish. You've already decided you need a SMTP client, when the problem you are trying to solve is something completely different...John-- John PeacockDirector of Information Research and TechnologyRowman & Littlefield Publishing Group4501 Forbes BoulevardSuite HLanham, MD 20706301-459-3366 x.5010fax 301-429-5748-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/
John Peacock
DOWNLOAD WEBDNA NOW!
Top Articles:
Talk List
The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...
Related Readings:
[redirect] w/o showing args? (1999)
Changing buttons (1999)
Displaying photo attached to first record (1997)
shipcost (1997)
Show shoppingcart after remove last item (1997)
WebMerch/Emailer Error (1998)
how to put/keep product customization info in basket? (1998)
[WebDNA] MIDDLE problems (2012)
WebDNA Examples - Call for submission... (1998)
RE: Webcat 2.0.1b1 bug with IE 3.01/4.0p1 (1997)
Adding Multiple Items to Shopping Cart from a Resultspage (1997)
OT: Java1.3.0 (2002)
Reversed words (1997)
Re1000001: Setting up shop (1997)
linetiems in thankyou.tpl (1997)
Search (1997)
Web Catalog 2 demo (1997)
SKU lookup (1997)
Problems with [Search] param - Mac Plugin b15 (1997)
WebCatalog NT beta 18 problem (1997)