|
Mailing Lists
|
Home /
Groups /
ColdFusion Talk (CF-Talk)
Display multiple Line items in CFMail
Author: Pascal Peters
Short Link: http://www.houseoffusion.com/groups/cf-talk/thread.cfm/threadid:32155#161385
You can put a <cfoutput> in the <cfmail> tag to loop over the grouped
records.
Same as <cfoutput group=...>
This code works fine in CF5. I'm not running CFMX right now, so I didn't
test.
<cfmail query="qTest" from="#variables.from#" to="#qTest.email#"
group="email" subject="test">
<cfoutput>
#qTest.text#
</cfoutput>
</cfmail>
Pascal
----- Excess quoted text cut - see Original Post for more -----
Author: Philip Arnold
Short Link: http://www.houseoffusion.com/groups/cf-talk/thread.cfm/threadid:32155#161347
----- Excess quoted text cut - see Original Post for more -----
If I'm understand what you're trying to do
Don't send the CFMAIL with the QUERY paramter, but build the content
before you send the CFMAIL
Author: Barney Boisvert
Short Link: http://www.houseoffusion.com/groups/cf-talk/thread.cfm/threadid:32155#161342
In CFMX, you can set a recordset cell to be another recordset. You could
preprocess your recordset converting the per-person part list to a nested
recordset, and then your CFMAIL wouldn't use grouping. IN each message,
you'd just loop over the inner recordset to output the list.
If you go that route, you have to dereference the inner recordset to a
'normal' variable before you can use it, you can't just reference the
recordset column that holds it.
Cheers,
barneyb
----- Excess quoted text cut - see Original Post for more -----
Author: Ben Densmore
Short Link: http://www.houseoffusion.com/groups/cf-talk/thread.cfm/threadid:32155#161339
Does someone have a solution for displaying multiple line items in
CFMail when you use the group attribute in a <cfoutput> tag?
I have a query that returns some order information that could have
multiple part numbers. I am grouping on the order number so when an
email goes out it doesn't send the same email more than once if they
have multiple part numbers.
The problem is that by grouping it, it will only display one part number
in the email. If I output the page I can use a regular <cfoutput> tag
nested inside of the grouped <cfoutput> tag which gives me all the part
numbers ordered for a specific customer, but trying to do that in CFMail
causes the code to break.
I can't seem to think of a way to do this.
Thanks,
Ben
|
May 24, 2012
|
Latest Fusion Authority Articles
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||