We've taken very similar approaches, although haven't done the same thing.


What happens if you do not have a default value for "server" (as an example) and none is provided? Do you take care of that optionally, or is it all set in the XML file?



At 11:23 AM 11/10/2003 -0500, you wrote:
I've done something very similar here. Although I'm using a very simple
XML file to configure each email, with the option to override those
values through a passed argument.

sendEmail(template, emailOptions, emailVars);

The template is an XML file:

<email to="" from="" cc="" bcc="" subject="" type="" ...>
Hello #username#,
This is a test email.
</email>

emailOptions is a structure with corresponding keys (to, from, bcc)
which will overwrite any default values specified in the XML file.

emailVars is a structure that contains any variables used within the
body of the email. In the above example the only key would be
'username'.

This is a bit different from how you are handling, but it works well for
us here. I can send the XML file to the tech writers and have them draft
the email directly. Plus you can add methods within sendEmail to create
logs when mail is sent.

Adam Wayne Lehman
Web Systems Developer
Johns Hopkins Bloomberg School of Public Health
Distance Education Division



--
Jeffry Houser, Web Developer <mailto:[EMAIL PROTECTED]>
Aaron Skye, Guitarist / Songwriter <mailto:[EMAIL PROTECTED]>
--
AIM: Reboog711 | Phone: 1-203-379-0773
--
My Books: <http://www.instantcoldfusion.com>
Recording Music: <http://www.fcfstudios.com>
Original Energetic Acoustic Rock: <http://www.farcryfly.com>



----------------------------------------------------------
You are subscribed to cfcdev. To unsubscribe, send an email
to [EMAIL PROTECTED] with the word 'unsubscribe cfcdev' in the message of the email.


CFCDev is run by CFCZone (www.cfczone.org) and supported
by Mindtool, Corporation (www.mindtool.com).

An archive of the CFCDev list is available at www.mail-archive.com/[EMAIL PROTECTED]

Reply via email to