[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

RE: Help Me with shell script please



>
> Thanks Ben Yau
> There is one another problem in this case...
> when you send this email to the people from the emails.txt list, they
> receive the message, but the do not see their names in the TO field. they
> can see the FROM address, but they do not have any entry in the TO field.
>
> Regards
> Rudolf
>

This happens if you don't include a "To:" line in the actual message body.
This is something that you will see in sendmail but not mail.

Here is the relevant part of the script (in the "form message" section)

> > # form message
> > echo "Subject: this is your subject" > ./messageout.txt
> > echo "To: $a" >> ./messageout.txt"
> > echo "" >> ./messageout.txt"
> > cat ./message.txt >> ./messageout.txt
> >

Try this as a test.
\
Create a file called "messagetest.txt" containing the following 4 lines
(including the blank line)

Subject: test subject
To: youraddress you com

Ths is a test


Then do this command
# cat messagetest.txt | /usr/lib/sendmail -f fromaddress from com
youraddress you com


The "To:" header will be taken from the file.

Ben Yau






[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]