<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: email script help needed in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/email-script-help-needed/m-p/2630753#M41129</link>
    <description>Hello Troy.&lt;BR /&gt;&lt;BR /&gt;One way is to use sendmail directly. Here's how: Suppose you want to send a file named "TEST" to troy@domain.com and troy@foo.com as if coming from mysteryuser@foo.com. You can do something like that:&lt;BR /&gt;&lt;BR /&gt;temp=/tmp/mail.$$&lt;BR /&gt;&lt;BR /&gt;echo "From: mysteryuser@foo.com" &amp;gt;&amp;gt;$temp&lt;BR /&gt;echo "To: troy@domain.com, troy@foo.com" &amp;gt;&amp;gt;$temp&lt;BR /&gt;echo "Subject: This is the subject" &amp;gt;&amp;gt;$temp&lt;BR /&gt;echo "" &amp;gt;&amp;gt;$temp&lt;BR /&gt;cat $temp TEST | /usr/sbin/sendmail -t&lt;BR /&gt;rm -f $temp&lt;BR /&gt;&lt;BR /&gt;You can even do it without intermediate files. All you need are your standard RFC822 headers (From, To, Subject) and a blank line before the mail itself. Sendmail will do the rest for you. Also note that this will only work if the sending user is a 'trusted' user (see /etc/sendmail.cf).&lt;BR /&gt;&lt;BR /&gt;Hope it helps,&lt;BR /&gt;Paga&lt;BR /&gt;</description>
    <pubDate>Wed, 12 Dec 2001 23:04:42 GMT</pubDate>
    <dc:creator>Marco Paganini</dc:creator>
    <dc:date>2001-12-12T23:04:42Z</dc:date>
    <item>
      <title>email script help needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/email-script-help-needed/m-p/2630752#M41128</link>
      <description>I have a Progress driven application running on HPUX 11.&lt;BR /&gt;&lt;BR /&gt;The application has the ability to send data to what it calls a printer. But all it really does is call a unix print command. I found that I can insert any unix command and it will run. So I started messing with scripts to achieve various goals. &lt;BR /&gt;&lt;BR /&gt;The latest one is to take the standard output, write it to a file, then afterwards send the file as an attachment in an email.&lt;BR /&gt;&lt;BR /&gt;I managed to get it to work, but not quite right. Now it is over my head. The problem is that the script sends out the email to 2 recipients. One is the one I intend the other is a default email address based on the user who invokes the script. I do not want to email going to anywhere other then the single email address that I define inside the script. The other problem is that the 'from' address is incorrect. I want to be able to define the 'from' address, so the receiver of the email can respond.&lt;BR /&gt;&lt;BR /&gt;The email is generated in unix, sending output generated in a Progress application. But the reply address should not be back to the unix box, but instead a definable email address of a specific user.&lt;BR /&gt;&lt;BR /&gt;I am including the script for you all to look at, and give any suggestions.&lt;BR /&gt;&lt;BR /&gt;Thanks.&lt;BR /&gt;&lt;BR /&gt;I hope this is clear as mud. ..</description>
      <pubDate>Wed, 12 Dec 2001 22:41:06 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/email-script-help-needed/m-p/2630752#M41128</guid>
      <dc:creator>Shar Hunter</dc:creator>
      <dc:date>2001-12-12T22:41:06Z</dc:date>
    </item>
    <item>
      <title>Re: email script help needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/email-script-help-needed/m-p/2630753#M41129</link>
      <description>Hello Troy.&lt;BR /&gt;&lt;BR /&gt;One way is to use sendmail directly. Here's how: Suppose you want to send a file named "TEST" to troy@domain.com and troy@foo.com as if coming from mysteryuser@foo.com. You can do something like that:&lt;BR /&gt;&lt;BR /&gt;temp=/tmp/mail.$$&lt;BR /&gt;&lt;BR /&gt;echo "From: mysteryuser@foo.com" &amp;gt;&amp;gt;$temp&lt;BR /&gt;echo "To: troy@domain.com, troy@foo.com" &amp;gt;&amp;gt;$temp&lt;BR /&gt;echo "Subject: This is the subject" &amp;gt;&amp;gt;$temp&lt;BR /&gt;echo "" &amp;gt;&amp;gt;$temp&lt;BR /&gt;cat $temp TEST | /usr/sbin/sendmail -t&lt;BR /&gt;rm -f $temp&lt;BR /&gt;&lt;BR /&gt;You can even do it without intermediate files. All you need are your standard RFC822 headers (From, To, Subject) and a blank line before the mail itself. Sendmail will do the rest for you. Also note that this will only work if the sending user is a 'trusted' user (see /etc/sendmail.cf).&lt;BR /&gt;&lt;BR /&gt;Hope it helps,&lt;BR /&gt;Paga&lt;BR /&gt;</description>
      <pubDate>Wed, 12 Dec 2001 23:04:42 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/email-script-help-needed/m-p/2630753#M41129</guid>
      <dc:creator>Marco Paganini</dc:creator>
      <dc:date>2001-12-12T23:04:42Z</dc:date>
    </item>
    <item>
      <title>Re: email script help needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/email-script-help-needed/m-p/2630754#M41130</link>
      <description>Thanks a lot!&lt;BR /&gt;&lt;BR /&gt;This is a perfect example of why I always look for help here! It is fast and efficient.&lt;BR /&gt;&lt;BR /&gt;The suggestion worked perfectly. We just added email ability to our old clunky application - no need for the expensive upgrade now!&lt;BR /&gt;&lt;BR /&gt;ha ha.&lt;BR /&gt;&lt;BR /&gt;Thanks. This solution is exactly what I needed.</description>
      <pubDate>Thu, 13 Dec 2001 00:32:07 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/email-script-help-needed/m-p/2630754#M41130</guid>
      <dc:creator>Shar Hunter</dc:creator>
      <dc:date>2001-12-13T00:32:07Z</dc:date>
    </item>
    <item>
      <title>Re: email script help needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/email-script-help-needed/m-p/2630755#M41131</link>
      <description>Troy, I was looking through, and noticed your issue was very similar to one I'm facing. If you don't mind my asking what progress DB product are you using?&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;&lt;BR /&gt;Joe Gilligan</description>
      <pubDate>Fri, 28 Dec 2001 21:28:56 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/email-script-help-needed/m-p/2630755#M41131</guid>
      <dc:creator>Joe Gilligan</dc:creator>
      <dc:date>2001-12-28T21:28:56Z</dc:date>
    </item>
    <item>
      <title>Re: email script help needed</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/email-script-help-needed/m-p/2630756#M41132</link>
      <description>Sure no prob.&lt;BR /&gt;&lt;BR /&gt;We are using Trend, which is now called Nxtrend.&lt;BR /&gt;&lt;BR /&gt;It is a wholesale warehousing application designed to handle inventory and sales.&lt;BR /&gt;&lt;BR /&gt;Troy</description>
      <pubDate>Fri, 28 Dec 2001 21:41:42 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/email-script-help-needed/m-p/2630756#M41132</guid>
      <dc:creator>Shar Hunter</dc:creator>
      <dc:date>2001-12-28T21:41:42Z</dc:date>
    </item>
  </channel>
</rss>

