<html>
<head>
<meta content="text/html; charset=windows-1252"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Karl,<br>
<br>
Me likes!<br>
<br>
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.<br>
<br>
But if people are happy to live with that as a compromise, I should
be able to work this in very easily.<br>
<br>
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/"><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.<br>
<br>
You can work around that by just hard-coding the start of the URL in
dropoff_email.tpl.<br>
You need to replace "{$zendToURL}" with something like
<a class="moz-txt-link-rfc2396E" href="https://zendto.your-company.com/"><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.<br>
<br>
I'm thinking about a solution to this...<br>
<br>
Cheers,<br>
Jules.<br>
<br>
<br>
<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 http-equiv="Content-Type" content="text/html;
charset=windows-1252">
<meta name="Generator" content="Microsoft Word 15 (filtered
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">
<p class="MsoNormal"><span style="color:#1F497D">Jules,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">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></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p
style="mso-margin-top-alt:0in;margin-right:0in;margin-bottom:0in;margin-left:.5in;margin-bottom:.0001pt;background:white"><em><span
style="font-size:10.5pt;font-family:"Arial",sans-serif;color:#707070">/*!</span></em><span
style="font-size:10.5pt;font-family:"Arial",sans-serif;color:#707070"><br>
<em><span style="font-family:"Arial",sans-serif">
@function deliverEmailHTML</span></em><o:p></o:p></span></p>
<p
style="mso-margin-top-alt:7.5pt;margin-right:0in;margin-bottom:0in;margin-left:.5in;margin-bottom:.0001pt;background:white;font-variant-ligatures:
normal;font-variant-caps: normal;orphans:
2;text-align:start;widows: 2;-webkit-text-stroke-width:
0px;word-spacing:0px">
<em><span
style="font-size:10.5pt;font-family:"Arial",sans-serif;color:#707070">
Send the $content of in an HTML formatted email message
to (one or more) address(es) in $toAddr.</span></em><span
style="font-size:10.5pt;font-family:"Arial",sans-serif;color:#707070"><br>
<em><span style="font-family:"Arial",sans-serif">*/</span></em><br>
<em><span style="font-family:"Arial",sans-serif">public
function deliverEmailHTML(</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
$toAddr,</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
$fromAddr,</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
$subject,</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
$content,</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
$headers = ""</span></em><br>
<em><span style="font-family:"Arial",sans-serif">)</span></em><br>
<em><span style="font-family:"Arial",sans-serif">{</span></em><br>
<em><span style="font-family:"Arial",sans-serif">//
If it contains any characters outside 0x00-0x7f, then
encode it</span></em><br>
<em><span style="font-family:"Arial",sans-serif">if
(preg_match('/[^\x00-\x7f]/', $subject)) {</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
$subject =
"=?UTF-8?B?".base64_encode(html_entity_decode($subject))."?=";</span></em><br>
<em><span style="font-family:"Arial",sans-serif">}</span></em><br>
<em><span style="font-family:"Arial",sans-serif">if
(preg_match('/[^\x00-\x7f]/', $fromAddr)) {</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
$fromAddr =
"=?UTF-8?B?".base64_encode(html_entity_decode($fromAddr))."?=";</span></em><br>
<em><span style="font-family:"Arial",sans-serif">}</span></em><br>
<em><span style="font-family:"Arial",sans-serif">if
(preg_match('/[^\x00-\x7f]/',
$this->_emailSenderAddr)) {</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
$sender =
"=?UTF-8?B?".base64_encode(html_entity_decode($this->_emailSenderAddr))."?=";</span></em><br>
<em><span style="font-family:"Arial",sans-serif">}
else {</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
$sender = $this->_emailSenderAddr;</span></em><br>
<em><span style="font-family:"Arial",sans-serif">}</span></em><o:p></o:p></span></p>
<p
style="mso-margin-top-alt:7.5pt;margin-right:0in;margin-bottom:0in;margin-left:.5in;margin-bottom:.0001pt;background:white;font-variant-ligatures:
normal;font-variant-caps: normal;orphans:
2;text-align:start;widows: 2;-webkit-text-stroke-width:
0px;word-spacing:0px">
<em><span
style="font-size:10.5pt;font-family:"Arial",sans-serif;color:#707070">//
Add the From: and Reply-To: headers if they have been
supplied.</span></em><span
style="font-size:10.5pt;font-family:"Arial",sans-serif;color:#707070"><br>
<em><span style="font-family:"Arial",sans-serif">if
($fromAddr!="") {</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
$headers = sprintf("From: %s", $sender) . PHP_EOL .</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
sprintf("Reply-to: %s", $fromAddr) . PHP_EOL .</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
$headers;</span></em><br>
<em><span style="font-family:"Arial",sans-serif">}</span></em><o:p></o:p></span></p>
<p
style="mso-margin-top-alt:7.5pt;margin-right:0in;margin-bottom:0in;margin-left:.5in;margin-bottom:.0001pt;background:white;font-variant-ligatures:
normal;font-variant-caps: normal;orphans:
2;text-align:start;widows: 2;-webkit-text-stroke-width:
0px;word-spacing:0px">
<em><span
style="font-size:10.5pt;font-family:"Arial",sans-serif;color:#707070">//
Add the MIME headers for 8-bit UTF-8 encoding</span></em><span
style="font-size:10.5pt;font-family:"Arial",sans-serif;color:#707070"><br>
<em><span style="font-family:"Arial",sans-serif">$headers
.= "MIME-Version: 1.0".PHP_EOL;</span></em><br>
<em><span style="font-family:"Arial",sans-serif">$headers
.= "Content-type: text/html;
charset=iso-8859-1".PHP_EOL;</span></em><br>
<em><span style="font-family:"Arial",sans-serif">$headers
.= "Content-Transfer-Encoding: 8bit".PHP_EOL;</span></em><o:p></o:p></span></p>
<p
style="mso-margin-top-alt:7.5pt;margin-right:0in;margin-bottom:0in;margin-left:.5in;margin-bottom:.0001pt;background:white;font-variant-ligatures:
normal;font-variant-caps: normal;orphans:
2;text-align:start;widows: 2;-webkit-text-stroke-width:
0px;word-spacing:0px">
<em><span
style="font-size:10.5pt;font-family:"Arial",sans-serif;color:#707070">return
mail(</span></em><span
style="font-size:10.5pt;font-family:"Arial",sans-serif;color:#707070"><br>
<em><span style="font-family:"Arial",sans-serif">
$toAddr,</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
$subject,</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
$content,</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
$headers // JKF Commented out for now due to security
concerns ,</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
// JKF Commented out for now due to security concerns</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
// '-f "'.$fromAddr.'"'</span></em><br>
<em><span style="font-family:"Arial",sans-serif">
);</span></em><br>
<em><span style="font-family:"Arial",sans-serif">}</span></em><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">--- Karl<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #E1E1E1
1.0pt;padding:3.0pt 0in 0in 0in">
<p 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">zendto-bounces@zend.to</a>
[<a class="moz-txt-link-freetext" href="mailto:zendto-bounces@zend.to">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"><zendto@zend.to></a><br>
<b>Subject:</b> Re: [ZendTo] Use different AD attribute<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal" style="margin-bottom:12.0pt">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:12.0pt"><o:p></o:p></span></p>
<div>
<p class="MsoNormal">On 22/02/2017 16:58, Karl Bundy wrote:<o:p></o:p></p>
</div>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<pre><span style="font-family:"Calibri",sans-serif;color:windowtext">Jules,</span><o:p></o:p></pre>
<pre><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:windowtext"> </span><o:p></o:p></pre>
<pre><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:windowtext">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="font-size:11.0pt;font-family:"Calibri",sans-serif;color:windowtext"> </span><o:p></o:p></pre>
<pre><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:windowtext">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="font-size:11.0pt;font-family:"Calibri",sans-serif;color:windowtext"> </span><o:p></o:p></pre>
<pre><img id="Picture_x0020_1" src="cid:part1.0BC2EE85.B3B59FFF@Zend.To" height="561" width="378"><o:p></o:p></pre>
<pre><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:windowtext"> </span><o:p></o:p></pre>
<pre><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:windowtext">Thanks,</span><o:p></o:p></pre>
<pre><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:windowtext"> </span><o:p></o:p></pre>
<pre><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:windowtext">Karl</span><o:p></o:p></pre>
<pre>_______________________________________________<o:p></o:p></pre>
<pre>ZendTo mailing list<o:p></o:p></pre>
<pre><a moz-do-not-send="true" href="mailto:ZendTo@zend.to">ZendTo@zend.to</a><o:p></o:p></pre>
<pre><a moz-do-not-send="true" href="http://mailman.ecs.soton.ac.uk/mailman/listinfo/zendto">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 moz-do-not-send="true" href="http://www.Zend.To">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>
</div>
<fieldset class="mimeAttachmentHeader"></fieldset>
<pre wrap="">_______________________________________________
ZendTo mailing list
<a class="moz-txt-link-abbreviated" href="mailto:ZendTo@zend.to">ZendTo@zend.to</a>
<a class="moz-txt-link-freetext" href="http://mailman.ecs.soton.ac.uk/mailman/listinfo/zendto">http://mailman.ecs.soton.ac.uk/mailman/listinfo/zendto</a></pre>
</blockquote>
<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">www.Zend.To</a>
Twitter: @JulesFM
PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415 B654
</pre></body></html>