Neither the WhatsNew file nor the help describes precisely how this option is used. Where do the images get embedded in the HTML message file?
This is potentially something I have long wanted. Until now, I have placed images that I want to include on a web server and use the img tag to display the image in the email message at the desired location. The problem with that is that some mail readers do not automatically display embedded images from a server.
The SMTP server is localhost. The server accepted the email and queued it for delivery (it can't really deliver it). The log doesn't look like there's a PNG in there.
And the biggest file in the outgoing queue is 855 bytes. I doubt it has a 1MB PNG file in it. I tried again specifying a JPG; that was no better.
FWIW, SENDMAIL does successfully send images as attachments (/A).
OK, I bit the bullet and installed TCMD30 so that I could experiment. I think I figured it out.
One uses /image=file arguments to specify files for use in the message. Then one uses normal img tags with the name of the file (without any path) to embed the image in the text. I wrote a test HTML file of the form:
That did just what I wanted; the image appeared between the two paragraphs.
However, when I tried to embed two images, the command line failed with the message "TCC: SMTP protocol error. 554 5.5.1 Error: no valid recipients." It appears that including two /image="filename" arguments messed up the parsing of the command. The help file does say "You can specify multiple /Image="..." arguments."
Whoa! When I omitted the second /image argument and sent the message, it actually worked! The message arrived with the TWO images embedded, even though the second one was not specified.
So, I removed BOTH /image arguments, and it still worked! That leaves me wondering just what the /image argument is actually doing.
Now I just tried the SENDHTML command in version 27, and it works there as well! I never realized that an img tag could reference a local file and cause that file to be encoded into the message.
Well, that led me to try one more experiment in verson 30. I put in the /image argument but did not include an img tag in the message file. The resulting message was just the same as using the command without the /image argument.
When I use an HTM file, the email accepted by the server does contain the specified image file. I can't test further because the email can't actually be delivered
But what role does any /image=file have on the message. As I reported, (1) it does not seem to be necessary to use such any such argument in order to embed a local image file and (2) contrary to the documentation, it seems that one cannot have more than one /image argument.
I wish that Rex would respond to this, as he must know what that argument was intended to accomplish and whether I am misunderstanding something about it.
By the way, Vince, why can't you send yourself a message? I had no trouble doing that (multiple times). I wrote a complex BTM file to implement a mass-mailing program. It uses a master HTML file with parameters that has data substituted from the mailing list using TPIPE to search-and-replace the parameter. Then the messages are sent using SENDHTML. I use that program frequently in my (volunteer) work.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.