<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.0.1" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>Gravity Support Forums Topic: Attach csv file to email in certain forms</title>
		<link>https://legacy.forums.gravityhelp.com/topic/attach-csv-file-to-email-in-certain-forms</link>
		<description>Gravity Support Forums Topic: Attach csv file to email in certain forms</description>
		<language>en-US</language>
		<pubDate>Mon, 20 Apr 2026 12:02:28 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.0.1</generator>
		<textInput>
			<title><![CDATA[Search]]></title>
			<description><![CDATA[Search all topics from these forums.]]></description>
			<name>q</name>
			<link>https://legacy.forums.gravityhelp.com/search.php</link>
		</textInput>
		<atom:link href="https://legacy.forums.gravityhelp.com/rss/topic/attach-csv-file-to-email-in-certain-forms" rel="self" type="application/rss+xml" />

		<item>
			<title>Chris Hajer on "Attach csv file to email in certain forms"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/attach-csv-file-to-email-in-certain-forms#post-85588</link>
			<pubDate>Wed, 31 Oct 2012 08:07:15 +0000</pubDate>
			<dc:creator>Chris Hajer</dc:creator>
			<guid isPermaLink="false">85588@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;What is &#34;the CSV for that form&#34;?  How is the CSV created and what does it contain?  It does not sound like it's related at all to your PDF attachments, but you just want to be able to use the same gform_user_notification_attachments hook and send another file when the submission is from another form.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>nsund on "Attach csv file to email in certain forms"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/attach-csv-file-to-email-in-certain-forms#post-85552</link>
			<pubDate>Wed, 31 Oct 2012 07:09:15 +0000</pubDate>
			<dc:creator>nsund</dc:creator>
			<guid isPermaLink="false">85552@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;HI&#60;/p&#62;
&#60;p&#62;This part works fine and when a person fills in one of the above forms they receive the pdf, however  I would like to be able to add so that if someone fills in form ID 20 for example that it sends them the csv file for that form and sends it as an attachment in the same email.&#60;br /&#62;
Is this possible?&#60;/p&#62;
&#60;p&#62;Thank you&#60;br /&#62;
Nic
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Chris Hajer on "Attach csv file to email in certain forms"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/attach-csv-file-to-email-in-certain-forms#post-85409</link>
			<pubDate>Wed, 31 Oct 2012 00:02:22 +0000</pubDate>
			<dc:creator>Chris Hajer</dc:creator>
			<guid isPermaLink="false">85409@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Thank you for starting a new topic. What is &#34;a file ID with the csv attached&#34;?  It sounds like you're trying to attach different files when different forms are submitted, or multiple files to some form submissions?  Can you give a scenario where this is in use?  Thank you.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>nsund on "Attach csv file to email in certain forms"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/attach-csv-file-to-email-in-certain-forms#post-84814</link>
			<pubDate>Mon, 29 Oct 2012 16:34:24 +0000</pubDate>
			<dc:creator>nsund</dc:creator>
			<guid isPermaLink="false">84814@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;HI&#60;/p&#62;
&#60;p&#62;I have the following code to attach documents in my functions.php file, if I wanted to add a file ID with the csv attached how would I amend the code so that it still sends these files and the csv to another form, for example form 1?&#60;br /&#62;
CODE in functions.php:&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;?php
add_filter(&#38;quot;gform_user_notification_attachments&#38;quot;, &#38;quot;add_attachment&#38;quot;, 10, 3);
function add_attachment($attachments, $lead, $form) {

    if ( $form[ &#38;#39;id&#38;#39; ] == 17 )  {
        $doc = &#38;#39;/The-Membership-Rules.pdf&#38;#39;;
    } elseif( $form[ &#38;#39;id&#38;#39; ] == 22 ) {
        $doc = &#38;#39;/The-Membership-Rules.pdf&#38;#39;;
    } else {
      $doc = &#38;#39;&#38;#39;;
    }

    $upload = wp_upload_dir();
    $upload_path = $upload[&#38;quot;basedir&#38;quot;];

    $attachments = array();
    $attachments[] = $upload_path . $doc;

    return $attachments;

}
?&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;Thanks&#60;br /&#62;
Nic
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
