<html><head>

<meta name="Generator" content="Novell Groupwise Client (Version 14.2.1  Build: 125886)">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head>
<body style="font: 10pt/normal Segoe UI; color: rgb(0, 0, 0); font-size-adjust: none; font-stretch: normal;"><div class="GroupWiseMessageBody" id="GroupWiseSection_1489065840000_kle@msktd.com_1FEF159614D20000B1ED8700B3004500_"><div>Jules,</div><div><br></div><div>You might want to check out <a href="https://github.com/PHPMailer/PHPMailer"><font color="#0066cc">https://github.com/PHPMailer/PHPMailer</font></a>&nbsp; It is actively supported.&nbsp; I use it for sending emails from our PHP based intranet and it works quite well.</div><div><br>Ken<br></div>
  
    
  
  <div class="GroupWiseMessageBody" id="GroupWiseSection_1489065840000_kle@msktd.com_1FEF159614D20000B1ED8700B3004500_"><span class="GroupwiseReplyHeader">&gt;&gt;&gt; Jules &lt;Jules@zend.to&gt; 3/9/2017 5:59 AM &gt;&gt;&gt;<br></span><div><span style="background-color: rgb(255, 255, 255);" bgcolor="#FFFFFF" text="#000000">&gt;
    Karl,<div><br></div><div>
    </div><div>
    I've thought of one problem of your approach: you should really put
    in both text and HTML variants of the message to create a
    multipart-alternative MIME message.</div><div>
    However, if there are any PHP libraries out there which will do the
    MIME encoding for me, I can just add a template file for the HTML
    part of the message, and build the entire MIME message from the text
    part (which we already have in place) and the new HTML part. That
    allows for the possibility of adding an image or two within the
    message as well.</div><div>
    </div><div>
    If anyone out there fancies a quick dig for how to create multipart
    MIME messages in PHP, please do let me know what you find.</div><div>
    </div><div>
    Cheers,</div><div>
    Jules.</div><div>
    </div><div>
    </div>
    <div class="moz-cite-prefix">On 08/03/2017 18:58, Jules wrote:<br>
    </div>
    <blockquote cite="mid:91f31582-9291-9755-0a1c-e398bc665f4d@Zend.To" type="cite">
      
      Karl,<div><br></div><div>
      </div><div>
      Me likes!</div><div>
      </div><div>
      That's simpler than what I originally had in mind, as you
      specifically are not embedding the image files. It does however
      mean that recipients who aren't displaying remote images have to
      click the "fetch the images" button in their mail client, which
      isn't *quite* as nice.</div><div>
      </div><div>
      But if people are happy to live with that as a compromise, I
      should be able to work this in very easily.</div><div>
      </div>
      BTW If you haven't spotted it yet, there's a bug in the way the
      "you haven't picked up your drop-off and it's about to expire"
      reminders are generated. Currently that means the URL to reach the
      download page is missing the <a class="moz-txt-link-rfc2396E" href="https://your-zendto.company.com/" moz-do-not-send="true"><font color="red"><b>MailScanner has detected a possible fraud attempt from "your-zendto.company.com" claiming to be</b></font> "https://your-zendto.company.com/"</a>
      off the front of it. So the links in the reminders don't work. The
      original messages sent out when the drop-off is created are fine,
      it's just the reminders when no one has picked up that drop-off at
      all, and it's about to expire.<div><br></div><div>
      </div><div>
      You can work around that by just hard-coding the start of the URL
      in dropoff_email.tpl.</div>
      You need to replace "{$zendToURL}" with something like <a class="moz-txt-link-rfc2396E" href="https://zendto.your-company.com/" moz-do-not-send="true"><font color="red"><b>MailScanner has detected a possible fraud attempt from "zendto.your-company.com" claiming to be</b></font> "https://zendto.your-company.com/"</a>
      or whatever is appropriate for you.<div><br></div><div>
      </div><div>
      I'm thinking about a solution to this...</div><div>
      </div><div>
      Cheers,</div><div>
      Jules.</div><div>
      </div><div>
      </div>
      <div class="moz-cite-prefix">On 08/03/2017 18:43, Karl Bundy
        wrote:<br>
      </div>
      <blockquote cite="mid:8b4731cadd00458b874878c52f82a597@MBX03B-IAD3.mex08.mlsrvr.com" type="cite">
        
        <meta name="Generator" content="Microsoft Word 15 (filtered&#10;          medium)">
        <!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]-->
        <style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;
        color:black;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:#0563C1;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:#954F72;
        text-decoration:underline;}
p
        {mso-style-priority:99;
        mso-margin-top-alt:auto;
        margin-right:0in;
        mso-margin-bottom-alt:auto;
        margin-left:0in;
        font-size:12.0pt;
        font-family:"Times New Roman",serif;}
pre
        {mso-style-priority:99;
        mso-style-link:"HTML Preformatted Char";
        margin:0in;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New";
        color:black;}
span.HTMLPreformattedChar
        {mso-style-name:"HTML Preformatted Char";
        mso-style-priority:99;
        mso-style-link:"HTML Preformatted";
        font-family:Consolas;
        color:black;}
span.EmailStyle19
        {mso-style-type:personal;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
span.EmailStyle20
        {mso-style-type:personal;
        font-family:"Calibri",sans-serif;
        color:#1F497D;}
span.EmailStyle21
        {mso-style-type:personal-reply;
        font-family:"Calibri",sans-serif;
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
        <div class="WordSection1">
          <div class="MsoNormal"><span style="color: rgb(31, 73, 125);">Jules,<o:p></o:p></span></div>
          <div class="MsoNormal"><span style="color: rgb(31, 73, 125);"><o:p> </o:p></span></div>
          <div class="MsoNormal"><span style="color: rgb(31, 73, 125);">All I did was
              create the new email template, added a new function to the
              NSSDropbox.php file (see below) based on the existing
              deliverEmail function, then changed the NSSDropoff.php
              file to use the new function and new template.  I did not
              embed/attach the image files, just set the URL in the HTML
              template.  There are more sophisticated ways to send HTML
              email, but the Mail function has the basics to get the job
              done. <o:p></o:p></span></div>
          <div class="MsoNormal"><span style="color: rgb(31, 73, 125);"><o:p> </o:p></span></div>
          <p style="background: white; margin-right: 0in; margin-bottom: 0pt; margin-left: 0.5in; mso-margin-top-alt: 0in;"><em><span style='color: rgb(112, 112, 112); font-family: "Arial",sans-serif; font-size: 10.5pt;'>/*!</span></em><span style='color: rgb(112, 112, 112); font-family: "Arial",sans-serif; font-size: 10.5pt;'><br>
              <em><span style='font-family: "Arial",sans-serif;'> 
                   @function deliverEmailHTML</span></em><o:p></o:p></span></p></div>
          <p style="background: white; margin-right: 0in; margin-bottom: 0pt; margin-left: 0.5in; word-spacing: 0px; orphans: 2; widows: 2; mso-margin-top-alt: 7.5pt; font-variant-ligatures: normal; font-variant-caps: normal; -webkit-text-stroke-width: 0px;"> <em><span style='color: rgb(112, 112, 112); font-family: "Arial",sans-serif; font-size: 10.5pt;'> 
                 Send the $content of in an HTML formatted email message
                to (one or more) address(es) in $toAddr.</span></em><span style='color: rgb(112, 112, 112); font-family: "Arial",sans-serif; font-size: 10.5pt;'></span><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>*/</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>public
                  function deliverEmailHTML(</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                   $toAddr,</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                   $fromAddr,</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                   $subject,</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                   $content,</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                   $headers = ""</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>)</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>{</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>//
                  If it contains any characters outside 0x00-0x7f, then
                  encode it</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>if
                  (preg_match('/[^\x00-\x7f]/', $subject)) {</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                   $subject =
                  "=?UTF-8?B?".base64_encode(html_entity_decode($subject))."?=";</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>}</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>if
                  (preg_match('/[^\x00-\x7f]/', $fromAddr)) {</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                   $fromAddr =
                  "=?UTF-8?B?".base64_encode(html_entity_decode($fromAddr))."?=";</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>}</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>if
                  (preg_match('/[^\x00-\x7f]/',
                  $this-&gt;_emailSenderAddr)) {</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                   $sender =
"=?UTF-8?B?".base64_encode(html_entity_decode($this-&gt;_emailSenderAddr))."?=";</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>}
                  else {</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                   $sender = $this-&gt;_emailSenderAddr;</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>}</span></em><o:p></o:p></blockquote></blockquote></span></div>
          <p style="background: white; margin-right: 0in; margin-bottom: 0pt; margin-left: 0.5in; word-spacing: 0px; orphans: 2; widows: 2; mso-margin-top-alt: 7.5pt; font-variant-ligatures: normal; font-variant-caps: normal; -webkit-text-stroke-width: 0px;"> <em><span style='color: rgb(112, 112, 112); font-family: "Arial",sans-serif; font-size: 10.5pt;'>//
                Add the From: and Reply-To: headers if they have been
                supplied.</span></em><span style='color: rgb(112, 112, 112); font-family: "Arial",sans-serif; font-size: 10.5pt;'></span><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>if
                  ($fromAddr!="") {</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                   $headers = sprintf("From: %s", $sender) . PHP_EOL .</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                      sprintf("Reply-to: %s", $fromAddr) . PHP_EOL .</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                      $headers;</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>}</span></em><o:p></o:p>
          <p style="background: white; margin-right: 0in; margin-bottom: 0pt; margin-left: 0.5in; word-spacing: 0px; orphans: 2; widows: 2; mso-margin-top-alt: 7.5pt; font-variant-ligatures: normal; font-variant-caps: normal; -webkit-text-stroke-width: 0px;"> <em><span style='color: rgb(112, 112, 112); font-family: "Arial",sans-serif; font-size: 10.5pt;'>//
                Add the MIME headers for 8-bit UTF-8 encoding</span></em><span style='color: rgb(112, 112, 112); font-family: "Arial",sans-serif; font-size: 10.5pt;'></span><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>$headers
                  .= "MIME-Version: 1.0".PHP_EOL;</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>$headers
                  .= "Content-type: text/html;
                  charset=iso-8859-1".PHP_EOL;</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>$headers
                  .= "Content-Transfer-Encoding: 8bit".PHP_EOL;</span></em><o:p></o:p></div>
          <p style="background: white; margin-right: 0in; margin-bottom: 0pt; margin-left: 0.5in; word-spacing: 0px; orphans: 2; widows: 2; mso-margin-top-alt: 7.5pt; font-variant-ligatures: normal; font-variant-caps: normal; -webkit-text-stroke-width: 0px;"> <em><span style='color: rgb(112, 112, 112); font-family: "Arial",sans-serif; font-size: 10.5pt;'>return
                mail(</span></em><span style='color: rgb(112, 112, 112); font-family: "Arial",sans-serif; font-size: 10.5pt;'></span><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                   $toAddr,</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                   $subject,</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                   $content,</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                   $headers // JKF Commented out for now due to security
                  concerns ,</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                   // JKF Commented out for now due to security concerns</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                    // '-f "'.$fromAddr.'"'</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'> 
                    );</span></em><div><br></div>
              <em><span style='font-family: "Arial",sans-serif;'>}</span></em><o:p></o:p>
          <div class="MsoNormal"><span style="color: rgb(31, 73, 125);"><o:p> </o:p></span></div>
          <div class="MsoNormal"><span style="color: rgb(31, 73, 125);"><o:p> </o:p></span></div>
          <div class="MsoNormal"><span style="color: rgb(31, 73, 125);">--- Karl<o:p></o:p></span></div>
          <div class="MsoNormal"><span style="color: rgb(31, 73, 125);"><o:p> </o:p></span></div>
          <div>
            <div style="border-width: 1pt medium medium; border-style: solid none none; border-color: rgb(225, 225, 225) currentColor currentColor; padding: 3pt 0in 0in; border-image: none;">
              <div class="MsoNormal"><b><span style="color: windowtext;">From:</span></b><span style="color: windowtext;"> <a class="moz-txt-link-abbreviated" href="mailto:zendto-bounces@zend.to" moz-do-not-send="true">zendto-bounces@zend.to</a>
                  [<a class="moz-txt-link-freetext" href="mailto:zendto-bounces@zend.to" moz-do-not-send="true">mailto:zendto-bounces@zend.to</a>]
                  <b>On Behalf Of </b>Jules<br>
                  <b>Sent:</b> Wednesday, March 08, 2017 11:19 AM<br>
                  <b>To:</b> ZendTo Users <a class="moz-txt-link-rfc2396E" href="mailto:zendto@zend.to" moz-do-not-send="true">&lt;zendto@zend.to&gt;</a><br>
                  <b>Subject:</b> Re: [ZendTo] Use different AD
                  attribute<o:p></o:p></span></div>
            </div>
          </div>
          <div class="MsoNormal"><o:p> </o:p></div>
          <div class="MsoNormal" style="margin-bottom: 12pt;">Karl,<br>
            <br>
            Yes, I agree this would be nice. I basically haven't had
            time to sort it all out. As I need to make the message a
            multipart MIME structure, the email templates get a *lot*
            more complicated.<br>
            <br>
            What did you have to change except for any templates/*.tpl
            files?<br>
            Any changes you make to the *.tpl files will <b>not</b> be
            overwritten when you upgrade later.<br>
            <br>
            So any hints you've got as to what I need to change in order
            to support the massively more complex MIME messages, please
            do let me know.<br>
            <br>
            Thanks!<br>
            Jules.<br>
            <br>
            <span style="font-size: 12pt;"><o:p></o:p></span></div>
          <div>
            <div class="MsoNormal">On 22/02/2017 16:58, Karl Bundy wrote:<o:p></o:p></div>
          </div>
          <blockquote style="margin-top: 5pt; margin-bottom: 5pt;">
            <pre><span style='color: windowtext; font-family: "Calibri",sans-serif;'>Jules,</span><o:p></o:p></pre>
            <pre><span style='color: windowtext; font-family: "Calibri",sans-serif; font-size: 11pt;'> </span><o:p></o:p></pre>
            <pre><span style='color: windowtext; font-family: "Calibri",sans-serif; font-size: 11pt;'>Thanks for all of your ongoing work on ZendTo, it has been a huge benefit for our team, and to the whole user community!  </span><o:p></o:p></pre>
            <pre><span style='color: windowtext; font-family: "Calibri",sans-serif; font-size: 11pt;'> </span><o:p></o:p></pre>
            <pre><span style='color: windowtext; font-family: "Calibri",sans-serif; font-size: 11pt;'>A feature request that I would love to see is the option for HTML formatted email notices.  They give a bit of polish to the system and oddly enough seem to give our users a bit more confidence in the system.  I have hacked our instance to send HTML formatted emails (see screenshot below) and I while what I have works fine, it would be great if this type of functionality was built-in to the system so that I don’t have to add back this functionality anytime we do upgrades.</span><o:p></o:p></pre>
            <pre><span style='color: windowtext; font-family: "Calibri",sans-serif; font-size: 11pt;'> </span><o:p></o:p></pre>
            <pre><img width="378" height="561" id="Picture_x0020_1" src="cid:HCJWULJIHWKH.IMAGE_8.jpeg"><o:p></o:p></pre>
<pre><span style='color: windowtext; font-family: "Calibri",sans-serif; font-size: 11pt;'> </span><o:p></o:p></pre>
<pre><span style='color: windowtext; font-family: "Calibri",sans-serif; font-size: 11pt;'>Thanks,</span><o:p></o:p></pre>
<pre><span style='color: windowtext; font-family: "Calibri",sans-serif; font-size: 11pt;'> </span><o:p></o:p></pre>
<pre><span style='color: windowtext; font-family: "Calibri",sans-serif; font-size: 11pt;'>Karl</span><o:p></o:p></pre>
<pre>_______________________________________________<o:p></o:p></pre>
<pre>ZendTo mailing list<o:p></o:p></pre>
<pre><a href="mailto:ZendTo@zend.to" moz-do-not-send="true">ZendTo@zend.to</a><o:p></o:p></pre>
<pre><a href="http://mailman.ecs.soton.ac.uk/mailman/listinfo/zendto" moz-do-not-send="true">http://mailman.ecs.soton.ac.uk/mailman/listinfo/zendto</a><o:p></o:p></pre>
</blockquote>
<pre>Jules<o:p></o:p></pre>
<pre><o:p> </o:p></pre>
<pre>-- <o:p></o:p></pre>
<pre>Julian Field MEng MBCS CITP CEng<o:p></o:p></pre>
<pre><o:p> </o:p></pre>
<pre>'Once is happenstance, twice is coincidence, three times is enemy<o:p></o:p></pre>
<pre> action.' - Ian Fleming<o:p></o:p></pre>
<pre><o:p> </o:p></pre>
<pre><a href="http://www.Zend.To" moz-do-not-send="true">www.Zend.To</a><o:p></o:p></pre>
<pre>Twitter: @JulesFM<o:p></o:p></pre>
<pre>PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415 B654<o:p></o:p></pre>





<fieldset class="mimeAttachmentHeader"></fieldset>
<pre wrap="">_______________________________________________
ZendTo mailing list
<a class="moz-txt-link-abbreviated" href="mailto:ZendTo@zend.to" moz-do-not-send="true">ZendTo@zend.to</a>
<a class="moz-txt-link-freetext" href="http://mailman.ecs.soton.ac.uk/mailman/listinfo/zendto" moz-do-not-send="true">http://mailman.ecs.soton.ac.uk/mailman/listinfo/zendto</a></pre>


<pre class="moz-signature" cols="72">Jules

-- 
Julian Field MEng MBCS CITP CEng

'There is one thing stronger than all the armies in the world;
 and that is an idea whose time has come.'

<a class="moz-txt-link-abbreviated" href="http://www.Zend.To" moz-do-not-send="true">www.Zend.To</a>
Twitter: @JulesFM
PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415 B654
</pre>



<pre class="moz-signature" cols="72">Jules

-- 
Julian Field MEng MBCS CITP CEng

'Adversity is like a strong wind. I don't mean just that it holds
 us back from places we might otherwise go. It also tears away from
 us all but the things that cannot be torn, so that afterward we see
 ourselves as we really are, and not merely as we might like to be.'
 - Arthur Golden

<a class="moz-txt-link-abbreviated" href="http://www.Zend.To">www.Zend.To</a>
Twitter: @JulesFM
PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415 B654
</pre></div></body></html>