<?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: send mail with embedded html plus .xls attachment in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759208#M610109</link>
    <description>My bad,&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://hpux.ws/mailfile2" target="_blank"&gt;http://hpux.ws/mailfile2&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;SEP</description>
    <pubDate>Mon, 28 Feb 2011 21:57:14 GMT</pubDate>
    <dc:creator>Steven E. Protter</dc:creator>
    <dc:date>2011-02-28T21:57:14Z</dc:date>
    <item>
      <title>send mail with embedded html plus .xls attachment</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759206#M610107</link>
      <description>I'm new to HP-UX and need some assistance in sending an email containing HTML body and a .csv attachment. I've found&lt;BR /&gt;numerous posts on the forum that discuss variations of this, however I cannot find a solution for this particular scenario.&lt;BR /&gt;&lt;BR /&gt;My .html file looks something like this:&lt;BR /&gt;&lt;BR /&gt;# cat email.html&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Sample HTML file&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;I'm able to send the html formatted email with no attachments using the following code: &lt;BR /&gt;&lt;BR /&gt;cat email.html \&lt;BR /&gt;| /usr/lib/sendmail -t "someone@domain.com"&lt;BR /&gt;&lt;BR /&gt;=====================================&lt;BR /&gt;When I update the code to include the attachement as follows, the email is sent with the attachment but the email body is missing: &lt;BR /&gt;&lt;BR /&gt;echo "To: $p_email\nSubject: $month $year Subject\n" &amp;gt; $mailfile&lt;BR /&gt;(cat email.html; \&lt;BR /&gt;uuencode ${ofile1} ${ofile1} &amp;gt;&amp;gt; $mailfile) \&lt;BR /&gt;| /usr/lib/sendmail -t &amp;lt; ${mailfile}&lt;BR /&gt;&lt;BR /&gt;=====================================&lt;BR /&gt;Next I tried the following and received the inline html email body but the .csv file was corrupt.&lt;BR /&gt;&lt;BR /&gt;export MAILTO=someone@domain.com&lt;BR /&gt;export SUBJECT="Test Waiver Code email"&lt;BR /&gt;export BODY=email.html&lt;BR /&gt;export ATTACH=wcode_hdr.csv&lt;BR /&gt;EMAIL_BOUNDARY_STRING=Z${RANDOM}${RANDOM}${RANDOM}${RANDOM}&lt;BR /&gt;&lt;BR /&gt;(&lt;BR /&gt; echo "To: $MAILTO"&lt;BR /&gt; echo "Subject: $SUBJECT"&lt;BR /&gt; echo "MIME-Version: 1.0"&lt;BR /&gt; echo 'Content-Type: multipart/mixed; boundary="${EMAIL_BOUNDARY_STRING}"'&lt;BR /&gt; echo '--${EMAIL_BOUNDARY_STRING}'&lt;BR /&gt;&lt;BR /&gt; echo "Content-Type: text/html charset=us-ascii"&lt;BR /&gt; echo "Content-Disposition: inline"&lt;BR /&gt; cat $BODY&lt;BR /&gt; echo '--${EMAIL_BOUNDARY_STRING}'&lt;BR /&gt; echo "Content-Transfer-Encoding: base64"  &lt;BR /&gt; echo 'Content-Disposition: attachment; filename="'$(basename $ATTACH)'"'&lt;BR /&gt; uuencode $ATTACH $(basename $ATTACH)&lt;BR /&gt;) | /usr/sbin/sendmail $MAILTO&lt;BR /&gt;&lt;BR /&gt;Any suggestions?&lt;BR /&gt;&lt;BR /&gt;Thanks</description>
      <pubDate>Mon, 28 Feb 2011 21:07:17 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759206#M610107</guid>
      <dc:creator>Lynne Frazier</dc:creator>
      <dc:date>2011-02-28T21:07:17Z</dc:date>
    </item>
    <item>
      <title>Re: send mail with embedded html plus .xls attachment</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759207#M610108</link>
      <description>Shalom,&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://hpux.ws/mailfile2" target="_blank"&gt;http://hpux.ws/mailfile2&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Try that script.&lt;BR /&gt;&lt;BR /&gt;Change the flipping email address though so my mailbox doesn't get filled.&lt;BR /&gt;&lt;BR /&gt;SEP</description>
      <pubDate>Mon, 28 Feb 2011 21:34:44 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759207#M610108</guid>
      <dc:creator>Steven E. Protter</dc:creator>
      <dc:date>2011-02-28T21:34:44Z</dc:date>
    </item>
    <item>
      <title>Re: send mail with embedded html plus .xls attachment</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759208#M610109</link>
      <description>My bad,&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://hpux.ws/mailfile2" target="_blank"&gt;http://hpux.ws/mailfile2&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;SEP</description>
      <pubDate>Mon, 28 Feb 2011 21:57:14 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759208#M610109</guid>
      <dc:creator>Steven E. Protter</dc:creator>
      <dc:date>2011-02-28T21:57:14Z</dc:date>
    </item>
    <item>
      <title>Re: send mail with embedded html plus .xls attachment</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759209#M610110</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;Please take a look to attached file.&lt;BR /&gt;&lt;BR /&gt;Rgds.</description>
      <pubDate>Mon, 28 Feb 2011 22:02:51 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759209#M610110</guid>
      <dc:creator>Jose Mosquera</dc:creator>
      <dc:date>2011-02-28T22:02:51Z</dc:date>
    </item>
    <item>
      <title>Re: send mail with embedded html plus .xls attachment</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759210#M610111</link>
      <description>Steven,&lt;BR /&gt;&lt;BR /&gt;It appears your example only sends an email with a file attached.  I need to attach a file as well as include inline html for the message body.&lt;BR /&gt;&lt;BR /&gt;Thanks</description>
      <pubDate>Tue, 01 Mar 2011 13:25:48 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759210#M610111</guid>
      <dc:creator>Lynne Frazier</dc:creator>
      <dc:date>2011-03-01T13:25:48Z</dc:date>
    </item>
    <item>
      <title>Re: send mail with embedded html plus .xls attachment</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759211#M610112</link>
      <description>Hi Lynne,&lt;BR /&gt;&lt;BR /&gt;Have you reviewed my attachment?&lt;BR /&gt;&lt;BR /&gt;Rgds.</description>
      <pubDate>Tue, 01 Mar 2011 13:30:51 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759211#M610112</guid>
      <dc:creator>Jose Mosquera</dc:creator>
      <dc:date>2011-03-01T13:30:51Z</dc:date>
    </item>
    <item>
      <title>Re: send mail with embedded html plus .xls attachment</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759212#M610113</link>
      <description>Jose,&lt;BR /&gt;&lt;BR /&gt;I tried your example and received the email with the attachement (not corrupted), but the inline html for the message body did not display correctly.  It displayed as a single text line of "email.html" instead of the actual verbiage within my file.  &lt;BR /&gt;&lt;BR /&gt;I used your code as follows:&lt;BR /&gt;&lt;BR /&gt;MAILTO=someone@domain.com&lt;BR /&gt;SUBJECT="Test Waiver Code email"&lt;BR /&gt;FROM=host@domain.com&lt;BR /&gt;BODY=`cat email.html`&lt;BR /&gt;ATTACH=wcode_hdr.csv&lt;BR /&gt;#&lt;BR /&gt;#And this last one send both of them, inside email body and an attachment:&lt;BR /&gt;&lt;BR /&gt;(echo "Subject:$SUBJECT\nTo: $MAILTO\nImportance:High\n\n$BODY";uuencode $ATTACH $ATTACH)| /usr/sbin/sendmail $MAILTO&lt;BR /&gt;&lt;BR /&gt;Thanks&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 01 Mar 2011 13:31:21 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759212#M610113</guid>
      <dc:creator>Lynne Frazier</dc:creator>
      <dc:date>2011-03-01T13:31:21Z</dc:date>
    </item>
    <item>
      <title>Re: send mail with embedded html plus .xls attachment</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759213#M610114</link>
      <description>Jose,&lt;BR /&gt;&lt;BR /&gt;Correction, I see a mistake in my code where I didn't cat the email.html file.  I fixed that but still the actual html code with tags is displayed in the email body as opposed to the inline formatted html verbiage.&lt;BR /&gt;&lt;BR /&gt;Lynne</description>
      <pubDate>Tue, 01 Mar 2011 14:09:15 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759213#M610114</guid>
      <dc:creator>Lynne Frazier</dc:creator>
      <dc:date>2011-03-01T14:09:15Z</dc:date>
    </item>
    <item>
      <title>Re: send mail with embedded html plus .xls attachment</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759214#M610115</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;Try this:&lt;BR /&gt;&lt;BR /&gt;(echo "Subject:$SUBJECT\nTo: $MAILTO\nImportance:High\n\n`cat email.html`";uuencode $ATTACH $ATTACH)|/usr/sbin/sendmail $MAILTO&lt;BR /&gt;&lt;BR /&gt;Rgds.</description>
      <pubDate>Tue, 01 Mar 2011 14:55:11 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759214#M610115</guid>
      <dc:creator>Jose Mosquera</dc:creator>
      <dc:date>2011-03-01T14:55:11Z</dc:date>
    </item>
    <item>
      <title>Re: send mail with embedded html plus .xls attachment</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759215#M610116</link>
      <description>Jose,&lt;BR /&gt;&lt;BR /&gt;I get the same results, the html is not formatted, the email body displays as follows:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Content-Transfer-Encoding: 7bit&lt;BR /&gt;Content-Type: text/html charset=us-ascii  &lt;BR /&gt; &lt;BR /&gt;&lt;DIV align="left"&gt;&lt;FONT face="Arialcolor=#000000size=2"&gt;Hello all,&lt;/FONT&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;BR /&gt;&lt;DIV align="left"&gt;&lt;FONT face="Arialcolor=#000000size=2"&gt;Please find the February 2011 waiver codes.  These waiver codes are intended for your use only and should not be forwarded to any other recipients.  Thank you!&lt;/FONT&gt;&lt;/DIV&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 01 Mar 2011 16:47:57 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759215#M610116</guid>
      <dc:creator>Lynne Frazier</dc:creator>
      <dc:date>2011-03-01T16:47:57Z</dc:date>
    </item>
    <item>
      <title>Re: send mail with embedded html plus .xls attachment</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759216#M610117</link>
      <description>Ok, so try this one syntax:&lt;BR /&gt;&lt;BR /&gt;(echo "Subject:$SUBJECT\nTo: $MAILTO\nImportance:High\nContent-Type: text/html; charset=us-ascii\n\n$BODY";uuencode $ATTACH $ATTACH)|/usr/sbin/sendmail $MAILTO&lt;BR /&gt;&lt;BR /&gt;Rgds.</description>
      <pubDate>Tue, 01 Mar 2011 17:04:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759216#M610117</guid>
      <dc:creator>Jose Mosquera</dc:creator>
      <dc:date>2011-03-01T17:04:45Z</dc:date>
    </item>
    <item>
      <title>Re: send mail with embedded html plus .xls attachment</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759217#M610118</link>
      <description>Tried that already, it removes the .csv attachment and the email body appears as follows:&lt;BR /&gt;&lt;BR /&gt;#Content-Type: text/html Content-Transfer-Encoding: 7bit Content-Type: text/html charset=us-ascii &lt;BR /&gt;Hello all,&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Please find the February 2011 waiver codes. These waiver codes are intended for your use only and should not be forwarded to any other recipients. Thank you!&lt;BR /&gt;&lt;BR /&gt;begin 644 wcode_hdr.csv M4%)!(%=A:79E&lt;B&gt;&lt;/B&gt;</description>
      <pubDate>Tue, 01 Mar 2011 17:10:46 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759217#M610118</guid>
      <dc:creator>Lynne Frazier</dc:creator>
      <dc:date>2011-03-01T17:10:46Z</dc:date>
    </item>
    <item>
      <title>Re: send mail with embedded html plus .xls attachment</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759218#M610119</link>
      <description>Well, I concentrate in the case that send html code as email body...&lt;BR /&gt;&lt;BR /&gt;MAILTO=someone@domain.com&lt;BR /&gt;SUBJECT="Test Waiver Code email"&lt;BR /&gt;BODY=`email.html`&lt;BR /&gt;HTMLFLAG="Content-type: text/html; charset=us-ascii\Content-Transfer-Encoding: 7bit\nMIME-Version: 1.0"&lt;BR /&gt;&lt;BR /&gt;(echo "Subject:$SUBJECT\nTo:$MAILTO\nImportance:High\n$HTMLFLAG\n\n$BODY")|/usr/sbin/sendmail -t&lt;BR /&gt;&lt;BR /&gt;Rgds.</description>
      <pubDate>Tue, 01 Mar 2011 19:43:14 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759218#M610119</guid>
      <dc:creator>Jose Mosquera</dc:creator>
      <dc:date>2011-03-01T19:43:14Z</dc:date>
    </item>
    <item>
      <title>Re: send mail with embedded html plus .xls attachment</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759219#M610120</link>
      <description>Same results...As soon as I code to include any of the following statements to recognize the html &amp;amp; attachment, it screws up the attachment.  I've tried different variations of the following:&lt;BR /&gt;&lt;BR /&gt;Content-Disposition: inline&lt;BR /&gt;Content-Type: text/html; charset=us-ascii&lt;BR /&gt;Content-Transfer-Encoding: 7bit&lt;BR /&gt;MIME-Version: 1.0&lt;BR /&gt;Content-Disposition: attachment; filename="'$(basename wcode_hdr.csv)'"&lt;BR /&gt;&lt;BR /&gt;I've been told it works on AIX using the -m flag with sendmail, but that flag is not available on HP-UX.  There must be something comparable.</description>
      <pubDate>Tue, 01 Mar 2011 19:57:25 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759219#M610120</guid>
      <dc:creator>Lynne Frazier</dc:creator>
      <dc:date>2011-03-01T19:57:25Z</dc:date>
    </item>
    <item>
      <title>Re: send mail with embedded html plus .xls attachment</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759220#M610121</link>
      <description>The content statements to recognize the inline html, work just fine without trying to also add a separate attachment.</description>
      <pubDate>Tue, 01 Mar 2011 20:20:25 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759220#M610121</guid>
      <dc:creator>Lynne Frazier</dc:creator>
      <dc:date>2011-03-01T20:20:25Z</dc:date>
    </item>
    <item>
      <title>Re: send mail with embedded html plus .xls attachment</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759221#M610122</link>
      <description>Yes, this happens because the html header forces attached file to be included as email body. If you copy the block from "begin" to "end" tags, pastes it on plain file and uudecode-it this you have the original attached file.&lt;BR /&gt;#man uuencode (is the same to uudecode)&lt;BR /&gt;&lt;BR /&gt;You must select the most convenient way to send it, as part of email body or an attached file. We worked for it!&lt;BR /&gt;&lt;BR /&gt;If you have felt assisted please do not forget assign points!&lt;BR /&gt;&lt;BR /&gt;Best regards&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 01 Mar 2011 21:25:49 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/send-mail-with-embedded-html-plus-xls-attachment/m-p/4759221#M610122</guid>
      <dc:creator>Jose Mosquera</dc:creator>
      <dc:date>2011-03-01T21:25:49Z</dc:date>
    </item>
  </channel>
</rss>

