Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

cfloop query ti cfmail missing first attachement

New Here ,
Jan 21, 2010 Jan 21, 2010

<cfquery name="895" datasource="85964">
SELECT name FROM 568 WHERE ID = #ID#
</cfquery>         

<cfloop query = "895">
<cfmail to="#form.email#" from="xx@xx.com" subject="#form.subject#" type="html">
<cfoutput><pre>#form.body#</pre></cfoutput>
<cfoutput><cfmailparam file="/45/#name#" type="application/pdf" /></cfoutput>
</cfmail>
</cfloop>

<cfdump var="#pdf_list#">

it dumps out 4 pdfs names but it send out only 3 every times it missies first file

640
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Explorer , Jan 24, 2010 Jan 24, 2010

Great.  Thanks for the update.

If you get a chance, please mark this topic as answered.

Translate
Explorer ,
Jan 24, 2010 Jan 24, 2010

Do you have any specific details you can share?

  • CF version
  • DBType / DB driver
  • Are you positive the query is returning (4) PDF files?
    • Can you verify this by just dumping the query instead of using cfmail?
  • Are you really naming you query with an invalid naming convention (varname = 895?)? (or were you just trying to use filler var names for this example)
  • Since you're not var-scoping (shame, shame), can you tell us what var scope the variable #pdf_list# is in and where it is being pre-defined?

--

JeffC

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jan 24, 2010 Jan 24, 2010

hi thanks for replay, but I figured out the issue, everything is fine its size of pdf which makes that pdf undeliverable.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Jan 24, 2010 Jan 24, 2010
LATEST

Great.  Thanks for the update.

If you get a chance, please mark this topic as answered.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources