I am using the below function and parameters
Here $c is TO address and $d is CC. But whenever ther is null in $c it is taking $d as in TO address.
My requirement is if there is null in $c then there should be no one in TO address and $d should be in CC.
Yoda is right. Try something more basic than mailx.
Perhaps mail is more basic.
But if your system has sendmail, go for it!
More customized for your needs
NB: there must be an empty line between mail header and mail body.
The sendmail program might hide in /usr/lib/
And if you want a To: line, just add it to the mail header! mailx and perhaps mail automatically place $address (the envelope) in a To: line,
Hi,
I am trying to send a mail using "mail" command in unix. I wanted to give sender name and sender address. I tried different options ,but still it shows only mail address(No name).
mail -s "Alert mail : Nothing running !!!" $email -- -F"Mail Alert" -fno-reply@alert.com
But I am getting... (4 Replies)
I have a file which contains few email address. I have few scripts which use the same mail address. so if any change in mail id like if any user do not want to receive the mail i can just edit a single file instead of many scripts. So i want the scripts to use that file. How can this be done. (2 Replies)
hello all
When i send an email using "mail" command, it is received by intended receiver but From Adress is getting displayed as user@hostname.
Is there any way to change the From address of Email to xxx@bbb.com?
Apprecite your response (2 Replies)
Hi folks
I need to write UNIX script (with ldapsearch) to query Active Directory. Input is NT login name and output is Email address.
Attached a screenshot of Sysinternals "AD Explorer". I need to do the same in CLI.
http://i.imgur.com/4s6FB.png
I am absolute LDAP/ldapsearch noob. (0 Replies)
I am testing a ksh script for email.
In the subject/content of the mail there is some dynamic variables like date and charges.
However these variables occupied the entire line erase other in that particular line
For e.g. there is a mail message:
This mail is intent...
Your total... (2 Replies)
Hello,
I am new to perl and need to create a script that will read a file and pull a name from the file and send e-mail.
How can I use the following awk statement in a perl script?
grep UNIXadmins /root/mail.conf | awk '{ print $2}'
and use the output to send a e-mail.
Any help would... (1 Reply)
Dear Brothers in Unix
I would like to change some HP-UX settings in order that the system send a message to root it should be copied to my e-mail address in Microsoft Exchange Server.
Please can you help me.
Best Regards and thanks in advance
Gege (2 Replies)
When sending emails to the outside world, aix present itself as d_prod@production1.pdc.itercom.org.
This is causing some issue with our e-mail server.
So we need to change the name to d_prod@itercom.org...
Does any one know how this can be accomplished?
Thank you (3 Replies)
Not sure if this is the right place to post this, but I thought I'd start here. Not really a Unix question, but I'm hoping the gurus here can help me in an area I know little about.
Someone got one of my credit card numbers. Tried to use it to charge a bunch of stuff over the internet. The... (4 Replies)