How can I make the below code fit in CFX_iMSMail tag?
It worked fine with cfmail but I'm having issues making
it work with the CFX tag. Thanks guys.
Jose
Old logic:
<CFOUTPUT QUERY="getRecpsGroup" group="CID">
<!--- gotta put cfmail all in one line to prevent unnecessary white space at
the top --->
<cfmail from="#attributes.from_address#" server="#attributes.mail_server#"
to="#Email#" subject="#attributes.title#" group="CID"
type="HTML"><CFMAILPARAM NAME="Reply-To"
value="#attributes.reply_to_address#">
<cfset content = attributes.content>
<cfset content = ReplaceNoCase(content, "*contact_id*", CID, "ALL")>
<cfset email_id=variables.last_email_id><cfset
content=ReplaceNoCase(content, "pr_e.cfm",
"pr_e.cfm?contact_id=#cid#&email_id=#variables.email_id#", "ALL")><cfset
content=ReplaceNoCase(content, "open_rate.cfm",
"open_rate.cfm?cid=#cid#&email_id=#variables.email_id#",
"ALL")>#variables.content#<cfinclude template="dsp_optout.cfm"><img
src="#this_campaign_dir#/open_rate.cfm?cid=#cid#&email_id=#variables.email_i
d#"></cfmail>
</cfoutput>
New logic:
<!--- set iMS variables --->
<cfset content = attributes.content>
<!--- not sure how to include the CID variable that comes from a query --->
<cfset content = ReplaceNoCase(content, "*contact_id*", "<:CID:>", "ALL")>
<cfset email_id=variables.last_email_id>
<cfset content=ReplaceNoCase(content, "pr_e.cfm",
"pr_e.cfm?contact_id=<:cid:>&email_id=#variables.email_id#", "ALL")>
<cfset content=ReplaceNoCase(content, "open_rate.cfm",
"open_rate.cfm?cid=<:cid:>&email_id=#variables.email_id#", "ALL")>
<cfset content=ReplaceNoCase(content, "open_rate.cfm",
"open_rate.cfm?cid=<:cid:>&email_id=#variables.email_id#", "ALL")>
<!--- disseminate with iMS --->
<cfx_imsmail query="getRecpsGroup" queryfield="email" qtoken_fname="fname"
qtoken_email="email" qtoken_cid="contact_id"
header_to="<:email:>" header_from="#attributes.from_address#" priority="0"
header_subject="#attributes.title#" SMTPFROM="#attributes.from_address#"
html="#variables.content#"
warnto="[EMAIL PROTECTED]"
log="yes">
==^=======================================================
This list server is Powered by iMS
"The Swiss Army Knife of Mail Servers"
--------------------------------------
To leave this list please complete the form at
http://www.coolfusion.com/iMSSupport.cfm
Need an iMS Developer license? Sign up for a free license here:
http://www.coolfusion.com/iMSDevelopers.cfm
List archives: http://www.mail-archive.com/infusion-email%40eoscape.com/
Note: You are subscribed as [email protected]
==^=======================================================