<?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: Posting data to more than one gravity form table</title>
		<link>https://legacy.forums.gravityhelp.com/topic/posting-data-to-more-than-one-gravity-form-table</link>
		<description>Gravity Support Forums Topic: Posting data to more than one gravity form table</description>
		<language>en-US</language>
		<pubDate>Sat, 02 May 2026 12:22:26 +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/posting-data-to-more-than-one-gravity-form-table" rel="self" type="application/rss+xml" />

		<item>
			<title>Chris Hajer on "Posting data to more than one gravity form table"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/posting-data-to-more-than-one-gravity-form-table#post-86556</link>
			<pubDate>Fri, 02 Nov 2012 06:31:27 +0000</pubDate>
			<dc:creator>Chris Hajer</dc:creator>
			<guid isPermaLink="false">86556@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Great. Thank you for the update.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>annaweaver on "Posting data to more than one gravity form table"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/posting-data-to-more-than-one-gravity-form-table#post-86217</link>
			<pubDate>Thu, 01 Nov 2012 11:01:05 +0000</pubDate>
			<dc:creator>annaweaver</dc:creator>
			<guid isPermaLink="false">86217@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Just got it to work. It took me a while to realise that I had to add $entry to the confirmation function parameters! Thank you for all your help Chris.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Chris Hajer on "Posting data to more than one gravity form table"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/posting-data-to-more-than-one-gravity-form-table#post-86147</link>
			<pubDate>Thu, 01 Nov 2012 08:38:07 +0000</pubDate>
			<dc:creator>Chris Hajer</dc:creator>
			<guid isPermaLink="false">86147@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Why are you using a function to return the confirmation message in this reply:&#60;br /&#62;
&#60;a href=&#34;http://www.gravityhelp.com/forums/topic/posting-data-to-more-than-one-gravity-form-table#post-86066&#34; rel=&#34;nofollow&#34;&#62;http://www.gravityhelp.com/forums/topic/posting-data-to-more-than-one-gravity-form-table#post-86066&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;You can certainly change the confirmation conditionally in your theme's functions.php, as you have done here, but it's easier to use the conditional shortcode, and then you also have access to the merge tags.  If you are going to do everything in a function, you will need to refer to the form fields by name in your query string.&#60;/p&#62;
&#60;p&#62;In your code, lines 5 and 6 will need to refer to the $entry, not the $form, to get the name and the email address, so it will look more like this, but will be specific to your form field IDs:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;// if your name is the first field on the the form
// 1.3 will be the first name
$firstname = $entry[&#38;quot;1.3&#38;quot;];
// if your email is field 2, this is correct
$email = $entry[&#38;quot;2&#38;quot;];&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;The field IDs depend on your actual form though.  View the source of the page where the form is rendered and you will see the field IDs and can use those.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>annaweaver on "Posting data to more than one gravity form table"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/posting-data-to-more-than-one-gravity-form-table#post-86071</link>
			<pubDate>Thu, 01 Nov 2012 05:14:23 +0000</pubDate>
			<dc:creator>annaweaver</dc:creator>
			<guid isPermaLink="false">86071@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Ok, so it's not showing the query string above... in the a tag i have&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;href=&#38;#39; . get_site_url() . &#38;#39;/lamp/mailing-list?firstname=&#38;#39; .  urlencode($firstname) . &#38;#39;&#38;amp;email=&#38;#39; . urlencode($email) . &#38;#39;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;If I hard code something in the urlencode brackets, rather than bringing in a variable, the fields in the following form get populated properly. I just don't know how to get the values from the first form into the query string! The field labels in the first from are firstname and email, and they have the same parameter names in the second form which needs populating.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>annaweaver on "Posting data to more than one gravity form table"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/posting-data-to-more-than-one-gravity-form-table#post-86066</link>
			<pubDate>Thu, 01 Nov 2012 05:08:26 +0000</pubDate>
			<dc:creator>annaweaver</dc:creator>
			<guid isPermaLink="false">86066@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Ok, it's so close to working! I'm just a bit stuck on how to send the form field values to the next form in a url string. Basically, I can't work out how to retrieve the field values properly to insert them into the query string. This is what I have so far in my functions.php.&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;add_filter(&#38;quot;gform_confirmation&#38;quot;, &#38;quot;custom_confirmation&#38;quot;, 10, 4);
function custom_confirmation($confirmation, $form, $lead, $ajax){
	// lamp contact form
    if($form[&#38;quot;id&#38;quot;] == &#38;quot;2&#38;quot;){
		$firstname = $form[&#38;quot;firstname&#38;quot;];
		$email = $form[&#38;quot;email&#38;quot;];
		$confirmation = &#38;#39;&#38;lt;p&#38;gt;Thank you, we will respond to your enquiry as soon as possible.&#38;lt;/p&#38;gt;Please click here if your would like to subscribe to our &#38;lt;a rel=&#38;quot;nofollow&#38;quot;&#38;gt;mailing list&#38;lt;/a&#38;gt;.&#38;lt;/p&#38;gt;&#38;#39;;
    }
	// lamp mailing list
    else if($form[&#38;quot;id&#38;quot;] == &#38;quot;1&#38;quot;){
        $confirmation = &#38;quot;Your details have been added to our mailing list, thank you.&#38;quot;;
    }
    return $confirmation;
}&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;Sorry, not sure how to use the backtack character to get this to display as code!
&#60;/p&#62;</description>
		</item>
		<item>
			<title>annaweaver on "Posting data to more than one gravity form table"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/posting-data-to-more-than-one-gravity-form-table#post-86030</link>
			<pubDate>Thu, 01 Nov 2012 03:48:36 +0000</pubDate>
			<dc:creator>annaweaver</dc:creator>
			<guid isPermaLink="false">86030@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I have been embedding this into my template file:&#60;br /&#62;
&#38;lt;?php echo do_shortcode( '[gravityform id=2 title=false description=false]' ); ?&#38;gt;&#60;/p&#62;
&#60;p&#62;Thank you for all this. I think having the link in the confirmation will be better actually. I will try following all your instructions and let you know how I get on!
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Chris Hajer on "Posting data to more than one gravity form table"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/posting-data-to-more-than-one-gravity-form-table#post-85863</link>
			<pubDate>Wed, 31 Oct 2012 16:38:37 +0000</pubDate>
			<dc:creator>Chris Hajer</dc:creator>
			<guid isPermaLink="false">85863@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I created form one (the contact form with more fields captured) first.  Then I created form two (the shorter/newsletter form).  In form 2, be sure to mark the first name, last name and email fields &#34;Allow field to be populated dynamically&#34; and then give those fields parameter names.  I used fname, lname and eml.  Then I created a page to embed each form into.  You will need to know the URL for form two so you can use it in your email notification (it could have been in the text confirmation as well; the visitor would have the link immediately after form submission if that were the case.) &#60;/p&#62;
&#60;p&#62;After that I used the conditional shortcodes, based on the value of the answer to the newsletter question (I used values of yes and no to make things easier on myself) to show some text in the confirmation message and the user notification conditionally.  In the user notification, I built a query string using the merge tag drop down, and that is where I use the URL for the page which holds the newsletter subscription page and also I use my parameter names of fname, lname and eml in addition to the merge tag drop down.&#60;/p&#62;
&#60;p&#62;Is that enough information to get you started?
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Chris Hajer on "Posting data to more than one gravity form table"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/posting-data-to-more-than-one-gravity-form-table#post-85858</link>
			<pubDate>Wed, 31 Oct 2012 16:33:08 +0000</pubDate>
			<dc:creator>Chris Hajer</dc:creator>
			<guid isPermaLink="false">85858@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Form 1 XML: &#60;a href=&#34;http://pastebin.com/download.php?i=PSRn6TJp&#34; rel=&#34;nofollow&#34;&#62;http://pastebin.com/download.php?i=PSRn6TJp&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;Form 2 XML: &#60;a href=&#34;http://pastebin.com/download.php?i=XwPKmxH1&#34; rel=&#34;nofollow&#34;&#62;http://pastebin.com/download.php?i=XwPKmxH1&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;Form 1 is embedded in this page:&#60;br /&#62;
&#60;a href=&#34;http://gravity.chrishajer.com/contact-form-step-1/&#34; rel=&#34;nofollow&#34;&#62;http://gravity.chrishajer.com/contact-form-step-1/&#60;/a&#62;&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;[gravityform id=&#38;quot;202&#38;quot; name=&#38;quot;Contact Form (step 1)&#38;quot; title=&#38;quot;false&#38;quot;]&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;Form 2 is embedded in this page:&#60;br /&#62;
&#60;a href=&#34;http://gravity.chrishajer.com/newsletter-confirmation/&#34; rel=&#34;nofollow&#34;&#62;http://gravity.chrishajer.com/newsletter-confirmation/&#60;/a&#62;&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;[php]
[gravityform id=&#38;quot;203&#38;quot; name=&#38;quot;Newsletter Form (step 2)&#38;quot; title=&#38;quot;false&#38;quot;]&#60;/code&#62;&#60;/pre&#62;</description>
		</item>
		<item>
			<title>Chris Hajer on "Posting data to more than one gravity form table"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/posting-data-to-more-than-one-gravity-form-table#post-85857</link>
			<pubDate>Wed, 31 Oct 2012 16:23:19 +0000</pubDate>
			<dc:creator>Chris Hajer</dc:creator>
			<guid isPermaLink="false">85857@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I configured two forms as I described above.  Start here:&#60;br /&#62;
&#60;a href=&#34;http://gravity.chrishajer.com/contact-form-step-1/&#34; rel=&#34;nofollow&#34;&#62;http://gravity.chrishajer.com/contact-form-step-1/&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;I will post the forms and the procedure in a little bit.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Chris Hajer on "Posting data to more than one gravity form table"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/posting-data-to-more-than-one-gravity-form-table#post-85840</link>
			<pubDate>Wed, 31 Oct 2012 15:04:44 +0000</pubDate>
			<dc:creator>Chris Hajer</dc:creator>
			<guid isPermaLink="false">85840@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;How are you hardcoding the shortcodes in the template?  I'm just curious.  If you embed the form using the function call in a template file, be sure you enqueue the required scripts.&#60;/p&#62;
&#60;p&#62;Documentation:&#60;br /&#62;
&#60;a href=&#34;http://www.gravityhelp.com/documentation/page/Embedding_A_Form#Function_Call&#34; rel=&#34;nofollow&#34;&#62;http://www.gravityhelp.com/documentation/page/Embedding_A_Form#Function_Call&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;I will take a look at configuring these forms and see if it's simple enough to do.  There are a few pieces to integrate but none of it seemed very complex.
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
