- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Scripted Email With Attachments *and* Nice Filenam...
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-16-2002 02:41 AM
тАО12-16-2002 02:41 AM
Scripted Email With Attachments *and* Nice Filename
I need to send an email with an attachment. I need to do this from a thrid-party application, so I need a command-line solution.
I'm using elm and I can send the attachment but the recipient sees the attachment with a name such as "name010.bin". Is it possible to supply a name for the file?
I'm using the following [include] statement in the body of my elm message:
[include $HOME/testhtmldocument.html html/octet-stream base64]
I'd like the recipient to see it as testhtmldocument.html instead of name010.bin!
I'm not tied to elm, so if elm can't do this but another scriptable email client can, I'd be happy to use that other solution.
Thanks in anticipation...
-Andy
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-16-2002 02:44 AM
тАО12-16-2002 02:44 AM
Re: Scripted Email With Attachments *and* Nice Filename
ux2dos name010.bin | uuencode testhtmldocument.html | mailx -m -s "attached file" you@where.you.are
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-16-2002 02:54 AM
тАО12-16-2002 02:54 AM
Re: Scripted Email With Attachments *and* Nice Filename
This will MIME encode a file of your choice and send via e-mail.
I don't use Elm but I would guess that it uuencodes the file for transmission. You'll be better off using mpack to MIME encode, as some mail clients struggle with uuencoded files, and simply display the encoded text in the mail client.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-17-2002 12:16 AM
тАО12-17-2002 12:16 AM
Re: Scripted Email With Attachments *and* Nice Filename
if U have sendmail of mailx
# uuencode name010.bin Nicefilename | /usr/lib/sendmail totheuser@user.com
Mailx
# uuencode name010.bin Nicefilename | mailx -s "Attachment" totheuser@user.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-17-2002 12:35 AM
тАО12-17-2002 12:35 AM
Re: Scripted Email With Attachments *and* Nice Filename
I use the following in my scripts:
/usr/bin/uuencode $logfile "The Name of the File that I want.lis"|mailx -m -s "The subject i want on `date`" $emailadd1
Hope this helps!
Yogeeraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-17-2002 12:01 PM
тАО12-17-2002 12:01 PM
Re: Scripted Email With Attachments *and* Nice Filename
I subsequently found that the renaming was being done by the recipeint's mail server! However, your replies have taught me a lot and have been most useful.
Cheers
-Andy