954,546 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Email attachment and add text inside the mail

Hi All

Anyway to add a note inside the email saying here is your file after attching a file in unix??

For example my script is fine attaching the excel file but i would like a message inside the mail too and not in the subject title.

/usr/bin/uuencode $adhocreport $adhocreport | /usr/bin/mailx -s "$subject" $destination
skelly16
Light Poster
34 posts since Aug 2007
Reputation Points: 10
Solved Threads: 0
 

should be a parameter to add content in mailx
have you looked at the manpage?

DimaYasny
Posting Virtuoso
Moderator
1,777 posts since Jan 2007
Reputation Points: 183
Solved Threads: 89
 
should be a parameter to add content in mailx have you looked at the manpage?


Sorry i have looked and cant find anything which would do this. If i try echoing this stop the mail attachment etc, also i dont want the message inside the subject line.

Im trying to achieve something like thisto: [email]joe.bloggs@hotmail.com[/email]
subject: Report of Adhoc

mailattachment.xls

Please find the report above etc blah blah.

Now everything works apart i dont know how to add comments after i have attached the excel file.

skelly16
Light Poster
34 posts since Aug 2007
Reputation Points: 10
Solved Threads: 0
 
DimaYasny
Posting Virtuoso
Moderator
1,777 posts since Jan 2007
Reputation Points: 183
Solved Threads: 89
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You