Title: Message
I do this frequently... what I do is build the output page the way I want it and then do a CFHTTP request from inside the mail tag - not pretty, but effective.
 
<cfmail from=[EMAIL PROTECTED] to=[EMAIL PROTECTED] subject="THE PAGE" type="html">
<cfhttp method="Get" url="" href="http://www.site.com/outputpage.cfm">http://www.site.com/outputpage.cfm resolveurl="Yes"/>
#cfhttp.FileContent# <br>
</cfmail>
 
Doug Teetzen
Bushnell Performance Optics
 


From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Adaryl Wakefield
Sent: Monday, May 24, 2004 2:13 PM
To: [EMAIL PROTECTED]
Subject: Re: [KCFusion] cfmail

I had actually considered that. Its a tad more complicated cause its and html formatted email so it would be one hell of a concatenated string which I was trying to avoid but I'll try it. I'll foward two examples so you can kind of see what it is supposed to look like.
Its basicly a cleaner version of this page
 
 
Adaryl "Did you reboot?" Wakefield
Aviator by passion
Programmer by sheer force of will
----- Original Message -----
Sent: Monday, May 24, 2004 1:59 PM
Subject: RE: [KCFusion] cfmail

If you emailing a single person or the content of the CFMAIL body contains the same information for everyone, you can build the Body portion of the CFMAIL tag prior to using the CFMAIL tag.

Example:
<CFSET EmailBody = "">
 
<--- Perform a query, loop, etc. and add the results to the EmailBody variable: --->
<CFQUERY NAME="Info" DATASOURCE="Test">
SELECT * FROM TEST
</CFQUERY>
<CFOUTPUT QUERY="Info">
<CFSET EmailBody = EmailBody + "Question: " + Info.Question + " Answer: " + Info.Answer + "<BR>">
</CFOUTPUT>
 
<CFMAIL TO="" FROM="">
#variables.EmailBody#
</CFMAIL>
 
 
Randy Ellis
City of Overland Park
Senior Programmer Analyst
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Adaryl Wakefield
Sent: Monday, May 24, 2004 1:40 PM
To: [EMAIL PROTECTED]
Subject: [KCFusion] cfmail

I am struggling with a work around for the cfmail tag. Im yanking some info that needs to be grouped properly the problem is I can't seem to do it right in a cfmail tag. ive got this
 
SELECT   table1.Category, table2.question, table3.answer, table4.url, table4.urlText, table2.question_ID
FROM      table1, table2, table3, table4
WHERE  table1.cat_num = table2.cat_num AND table2.question_ID = table3.question_ID AND table2.question_ID *= table4.question_ID and table2.question_ID = #url.id#
 
the information from table1 and table2 only needs to come out once. the information from table3 and table4 need to come out grouped on table2.question_ID
 
I can't group in a loop and I can't leave the query attribute out of the mail tag and just use cfoutput cause it tosses and error.
Im using CFMX on Win2k
 
Adaryl "Did you reboot?" Wakefield
Aviator by passion
Programmer by sheer force of will

Reply via email to