Sponsored Content
Top Forums Programming Perl - EMail issue - NEED Help Post 302995074 by durden_tyler on Friday 31st of March 2017 11:50:35 AM
Old 03-31-2017
Quote:
Originally Posted by mrn6430
...
Code:
  $includeListEmail = "NPSTool.IncludeListEmail.txt";
     if ($emailFlag eq "Y") {
        `uuencode ${includeListEmail} Included.doc > /tmp/test.Included.doc`;
        `uuencode ${excludeListEmail} Excluded.doc > /tmp/test.Excluded.doc`;
        `echo|mailx -s "TOOL: $myScenario" -a /tmp/test.Included.doc -a /tmp/test.Excluded.doc myemail@yahoo.com`;
        }

...
With "mailx -a" you do not need the uuencode command.
Try something like this:

Code:
 echo "Text_for_email_body" | mailx -s "Email_subject" -a NPSTool.IncludeListEmail.txt <recipient_email_address>

 

10 More Discussions You Might Find Interesting

1. Solaris

Crontab email issue

Hi, I have a script that sends a db extract file as an email attachment. I have a crontab created to run it everyday at 8 am.. 00 08 * * * ksh /home/rtaaa/tbasd/report.sh > /home/rtaaa/tbasd/logs/report.log When i just run the "ksh /home/rtaaa/tbasd/report.sh >... (5 Replies)
Discussion started by: ryannam
5 Replies

2. UNIX for Advanced & Expert Users

strange aunthentication issue with email

hi again i'm running a centos 4.x box with sendmail and openwebmail. I had a weird situation where users couldn't not get authenticated using a pop mail client but but were able to aunthenticate using the openwebmail webmail client. I looked through the logs and didn't see anything strange. I... (0 Replies)
Discussion started by: mcraul
0 Replies

3. Shell Programming and Scripting

Crontab issue: getting email but with out body

I have a oracle sh script test.sh #!/bin/bash R=`sqlplus -S *****/*********@dfsdf <<ENDOFSQL set serveroutput on size unlimited; execute DBMS_SNAPSHOT.REFRESH( '"MIS_ADMIN"."MV_SURVEY_UNITS_CENSUS"','F'); execute DBMS_SNAPSHOT.REFRESH( '"MIS_ADMIN"."MV_SURVEY_UNITS_CENSUS_PART"','F');... (1 Reply)
Discussion started by: ramkia6
1 Replies

4. Emergency UNIX and Linux Support

AIX: Production email issue

Hello, system generated emails sent to users from production scripts within Aix arent going out. In the errpt -a output I see: _______________________________________________________ LABEL: SRC_SVKO IDENTIFIER: BC3BE5A3 Date/Time: Tue Mar 13 16:28:07 EDT 2012 Sequence... (2 Replies)
Discussion started by: NycUnxer
2 Replies

5. Shell Programming and Scripting

issue with Email Body

Hi, I have written shell program to send email as below - #!/bin/ksh filename=`ls -ltrh *.Z` echo $filename |mailx -s "FOR TESTING" rahul.b@infotech.net I am getting the email but email body is - -rw-rw-r-- 1 bahulra dba 173M Mar 22 04:37 corphist.txt.Z -rw-rw-r-- 1 bahulra dba 107M... (3 Replies)
Discussion started by: rahulbahulekar
3 Replies

6. Forum Support Area for Unregistered Users & Account Problems

Email address change issue

Hi Neo/Scott, I decided to change my email address in my details from my earlier one to the one I got with my VIP membership. After the change, I got a message that I'll receive an activation link at the new address to re-activate my account. I haven't got that link till now. Also, all my... (3 Replies)
Discussion started by: elixir_sinari
3 Replies

7. Shell Programming and Scripting

UNIX email issue

Hi all, I have tried to send an email with the below script. but i am not getting the subject of the email where it is present in the simply.txt. I am using HP UNIX server. I am not sure what mistake i made in the below unix command. any help would be appreciated. cat simply.txt ... (2 Replies)
Discussion started by: arun888
2 Replies

8. Shell Programming and Scripting

Email issue

hi all, i am not getting with the email attached not sure what wrong with the syntax can u help me out plz. cat notavailabltext.txt please reach to team for any issues. uuencode notavailable.txt notavailable.txt | mailx -m -s "Files are available" arun@trival.com < notavailabltext.txt (6 Replies)
Discussion started by: arun888
6 Replies

9. Shell Programming and Scripting

Issue with email sent from Linux server

I have written a shell script to send email to users with message body and attachment. Message body has registered symbol. But when I receive the email, registered trademark symbol has a special character prefixed and appears carlington work® whereas I am expecting to see only carlington work® .... (3 Replies)
Discussion started by: Leo87
3 Replies

10. Shell Programming and Scripting

Mailx Email Issue

Hello, I am facing an issue with email in Linux. I am using mailx command to send email. When I give invalid domain address then it is taking both sender and recipient as sender email and trying to send email. Below is my command echo -e "${EMAIL_TEXT}" | mailx -v -s "${SUBJECT}" -r... (5 Replies)
Discussion started by: yuvi
5 Replies
uuencode(4)						     Kernel Interfaces Manual						       uuencode(4)

NAME
uuencode - format of an encoded uuencode file DESCRIPTION
Files output by consist of a header line followed by a number of body lines, and a trailer line. The command ignores any lines preceding the header or following the trailer (see uuencode(1)). Lines preceding a header must not look like a header. The header line consists of the word followed by a space, a mode (in octal), another space, and a string which specifies the name of the remote file. The body consists of a number of lines, each containing 62 or fewer characters (including trailing new-line). These lines consist of a character count, followed by encoded characters, followed by a newline. The character count is a single printing character, which represents an integer. This integer is the number of bytes in the rest of the line, and always ranges from 0 to 63. The byte count can be determined by subtracting the equivalent octal value of an ASCII space charac- ter (octal 40) from the character. Groups of 3 bytes are stored in 4 characters, 6 bits per character. All are offset by a space to make the characters printable. The last line may be shorter than the normal 45 bytes. If the size is not a multiple of 3, this fact can be determined by the value of the count on the last line. Extra meaningless data will be included, if necessary, to make the character count a multiple of 4. The body is terminated by a line with a count of zero. This line consists of one ASCII space. The trailer line consists of the word on a line by itself. SEE ALSO
mail(1), uuencode(1), uucp(1). uuencode(4)
All times are GMT -4. The time now is 09:50 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy