<?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: Populate Dynamically</title>
		<link>https://legacy.forums.gravityhelp.com/topic/populate-dinamically</link>
		<description>Gravity Support Forums Topic: Populate Dynamically</description>
		<language>en-US</language>
		<pubDate>Sun, 05 Apr 2026 12:23:39 +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/populate-dinamically" rel="self" type="application/rss+xml" />

		<item>
			<title>Chris Hajer on "Populate Dynamically"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/populate-dinamically#post-145285</link>
			<pubDate>Sat, 09 Feb 2013 19:03:59 +0000</pubDate>
			<dc:creator>Chris Hajer</dc:creator>
			<guid isPermaLink="false">145285@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Glad that solution will work for you.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Aejandro on "Populate Dynamically"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/populate-dinamically#post-145136</link>
			<pubDate>Sat, 09 Feb 2013 10:54:10 +0000</pubDate>
			<dc:creator>Aejandro</dc:creator>
			<guid isPermaLink="false">145136@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;You rock!!!&#60;/p&#62;
&#60;p&#62;It works like a charm.&#60;/p&#62;
&#60;p&#62;Thank you very much!!
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Chris Hajer on "Populate Dynamically"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/populate-dinamically#post-144997</link>
			<pubDate>Sat, 09 Feb 2013 01:36:32 +0000</pubDate>
			<dc:creator>Chris Hajer</dc:creator>
			<guid isPermaLink="false">144997@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I think I have it now.  I described a different way of getting the existing page title in the form entry.  You did not need that.&#60;/p&#62;
&#60;p&#62;In the page which sends a visitor to your form (I assume there are multiple pages all pointing to the same form?) you must have a link to the page where the form is embedded, correct?  If that is the case, then you can add query string parameters to that link.  The parameter will be &#34;pagetitle&#34; and you will just add it to the URL of the page where your form is embedded.&#60;/p&#62;
&#60;p&#62;So, if your existing URL was this:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;a href=&#38;quot;http://example.com/place-an-order/&#38;quot; rel=&#38;quot;nofollow&#38;quot;&#38;gt;Place your order now&#38;lt;/a&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;You would modify it to look like this and send the page title to the page with your form embedded:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;a href=&#38;quot;http://example.com/place-an-order/?pagetitle=Page Title of Page I was On&#38;quot; rel=&#38;quot;nofollow&#38;quot;&#38;gt;Place your order now&#38;lt;/a&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;That will capture &#34;Page Title of Page I was On&#34; in the field with the parameter name &#34;pagetitle&#34; which you checked so that it can &#34;Allow field to be populated dynamically&#34;.&#60;/p&#62;
&#60;p&#62;&#60;em&#62;Ignore the rel=&#34;nofollow&#34; stuff.  That is added by the forum software&#60;/em&#62;
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Aejandro on "Populate Dynamically"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/populate-dinamically#post-144913</link>
			<pubDate>Fri, 08 Feb 2013 21:33:47 +0000</pubDate>
			<dc:creator>Aejandro</dc:creator>
			<guid isPermaLink="false">144913@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Nope, it does not work for me.&#60;/p&#62;
&#60;p&#62;The goal is not to get the page title where the form is embedded.&#60;/p&#62;
&#60;p&#62;The goal is to get the page title where the visitor came from.&#60;/p&#62;
&#60;p&#62;I followed your instructions and here you have the link: &#60;a href=&#34;http://goo.gl/lt6hj&#34; rel=&#34;nofollow&#34;&#62;http://goo.gl/lt6hj&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;Thank you for your help.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Chris Hajer on "Populate Dynamically"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/populate-dinamically#post-144790</link>
			<pubDate>Fri, 08 Feb 2013 15:35:00 +0000</pubDate>
			<dc:creator>Chris Hajer</dc:creator>
			<guid isPermaLink="false">144790@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;In your page where the form is embedded, I assume you are using the shortcode to embed the form?  If that's the case, you can modify the shortcode to send field values to the form. You can send the page title in the shortcode.  There will need to be a field in the form to hold the page title, and it needs to be checked &#34;Allow field to be populated dynamically.&#34;  Give it a parameter name like &#34;pagetitle&#34; or something.  Then, in the shortcode you can do this:&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;[gravityform id=&#38;quot;3&#38;quot; name=&#38;quot;Form 3 Name&#38;quot; title=&#38;quot;false&#38;quot; ajax=&#38;quot;false&#38;quot; field_values=&#38;#39;pagetitle=This Page Title&#38;#39;]&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;Will that work for you?
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Aejandro on "Populate Dynamically"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/populate-dinamically#post-144370</link>
			<pubDate>Thu, 07 Feb 2013 18:58:44 +0000</pubDate>
			<dc:creator>Aejandro</dc:creator>
			<guid isPermaLink="false">144370@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I can not believe it was so obvious using merge tags.&#60;/p&#62;
&#60;p&#62;Also, I need to implement the other way: &#34;linking to the same one form from multiple pages, and want the page title that the visitor came from&#34;. How can it be achieved?&#60;/p&#62;
&#60;p&#62;Thank you,
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Chris Hajer on "Populate Dynamically"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/populate-dinamically#post-144202</link>
			<pubDate>Thu, 07 Feb 2013 11:44:43 +0000</pubDate>
			<dc:creator>Chris Hajer</dc:creator>
			<guid isPermaLink="false">144202@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;@Aejandro, if you are embedding the same form in every page, then you can set the default value of the field using this merge tag:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;{embed_post:post_title}&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;If you are linking to the same one form from multiple pages, and want the page title that the visitor came from, let us know that.  From your code, looks like you just want the post title for the current post, so the merge tag above should take care of that.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Aejandro on "Populate Dynamically"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/populate-dinamically#post-143908</link>
			<pubDate>Thu, 07 Feb 2013 01:34:46 +0000</pubDate>
			<dc:creator>Aejandro</dc:creator>
			<guid isPermaLink="false">143908@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Hello, I am using this code:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;add_filter(&#38;quot;gform_pre_render&#38;quot;, &#38;quot;populate_post_name&#38;quot;);
function populate_post_name($form){
	global $post;
	    if($form[&#38;quot;id&#38;quot;] != 1) // Change [2] to the ID of the form you want to use
	       return $form;
		$post_name = get_the_title($post-&#38;gt;ID);
		$form[&#38;quot;fields&#38;quot;][29][&#38;quot;defaultValue&#38;quot;] = $post_name ; //Change [3] to the nth (-1) field you want to populate.
		return $form;

}&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;The link: &#60;a href=&#34;http://goo.gl/m68vW&#34; rel=&#34;nofollow&#34;&#62;http://goo.gl/m68vW&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;Thanks
&#60;/p&#62;</description>
		</item>
		<item>
			<title>David Peralty on "Populate Dynamically"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/populate-dinamically#post-143867</link>
			<pubDate>Thu, 07 Feb 2013 00:05:23 +0000</pubDate>
			<dc:creator>David Peralty</dc:creator>
			<guid isPermaLink="false">143867@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;What code are you using exactly and can you link to your form?
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Aejandro on "Populate Dynamically"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/populate-dinamically#post-143646</link>
			<pubDate>Wed, 06 Feb 2013 18:05:22 +0000</pubDate>
			<dc:creator>Aejandro</dc:creator>
			<guid isPermaLink="false">143646@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Hello:&#60;/p&#62;
&#60;p&#62;My website has around 50 products and I want to use the same form for users enquire about them.&#60;/p&#62;
&#60;p&#62;The problem is how to know what product is the user enquiring about.&#60;/p&#62;
&#60;p&#62;So I need a single line text field be populated with the title of the &#34;product&#34; (custom post type).&#60;/p&#62;
&#60;p&#62;I was searching around and found this post: &#60;a href=&#34;http://www.gravityhelp.com/forums/topic/dynamically-populate-based-on-post-name&#34; rel=&#34;nofollow&#34;&#62;http://www.gravityhelp.com/forums/topic/dynamically-populate-based-on-post-name&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;But I am still not getting the single text field dinamically populated.&#60;/p&#62;
&#60;p&#62;Is anything I am missing? Anything I should double check?&#60;/p&#62;
&#60;p&#62;Thank you
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
