<?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: Drop Down of Posts in Category?</title>
		<link>https://legacy.forums.gravityhelp.com/topic/drop-down-of-posts-in-category</link>
		<description>Gravity Support Forums Topic: Drop Down of Posts in Category?</description>
		<language>en-US</language>
		<pubDate>Sun, 19 Apr 2026 23:38:21 +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/drop-down-of-posts-in-category" rel="self" type="application/rss+xml" />

		<item>
			<title>David Peralty on "Drop Down of Posts in Category?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/drop-down-of-posts-in-category#post-69215</link>
			<pubDate>Thu, 02 Aug 2012 15:43:30 +0000</pubDate>
			<dc:creator>David Peralty</dc:creator>
			<guid isPermaLink="false">69215@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Try changing it to category=61 and numberposts to a real number... say 10 or so and see if that works.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>staceyzav on "Drop Down of Posts in Category?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/drop-down-of-posts-in-category#post-69214</link>
			<pubDate>Thu, 02 Aug 2012 15:41:37 +0000</pubDate>
			<dc:creator>staceyzav</dc:creator>
			<guid isPermaLink="false">69214@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Hi  - I am doing something wrong!  I, too, want just a category to show up in my drop down.  The category name is Now Booking.  The slug is now-booking.  the cat id is 61.&#60;/p&#62;
&#60;p&#62;Here is my functions code that is currently pulling up ALL posts, not the specific category I am trying to get:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;?php

// update the &#38;#39;51&#38;#39; to the ID of your form
add_filter(&#38;#39;gform_pre_render_1&#38;#39;, &#38;#39;populate_posts&#38;#39;);
function populate_posts($form){

    foreach($form[&#38;#39;fields&#38;#39;] as &#38;amp;$field){

        if($field[&#38;#39;type&#38;#39;] != &#38;#39;select&#38;#39; &#124;&#124; strpos($field[&#38;#39;cssClass&#38;#39;], &#38;#39;populate-posts&#38;#39;) === false)
            continue;

        // you can add additional parameters here to alter the posts that are retreieved
        // more info: &#60;a href=&#34;http://codex.wordpress.org/Template_Tags/get_posts&#34; rel=&#34;nofollow&#34;&#62;http://codex.wordpress.org/Template_Tags/get_posts&#60;/a&#62;
        $posts = get_posts(&#38;#39;category=now-booking&#38;amp;numberposts=-1&#38;amp;post_status=publish&#38;#39;);

        // update &#38;#39;Select a Post&#38;#39; to whatever you&#38;#39;d like the instructive option to be
        $choices = array(array(&#38;#39;text&#38;#39; =&#38;gt; &#38;#39;Select a Post&#38;#39;, &#38;#39;value&#38;#39; =&#38;gt; &#38;#39; &#38;#39;));

        foreach($posts as $post){
            $choices[] = array(&#38;#39;text&#38;#39; =&#38;gt; $post-&#38;gt;post_title, &#38;#39;value&#38;#39; =&#38;gt; $post-&#38;gt;post_title);
        }

        $field[&#38;#39;choices&#38;#39;] = $choices;

    }

    return $form;
}&#60;/code&#62;&#60;/pre&#62;</description>
		</item>
		<item>
			<title>812studio on "Drop Down of Posts in Category?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/drop-down-of-posts-in-category#post-65097</link>
			<pubDate>Fri, 06 Jul 2012 18:40:30 +0000</pubDate>
			<dc:creator>812studio</dc:creator>
			<guid isPermaLink="false">65097@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;This is close to what I want to do, but I want to add in extra info to:&#60;/p&#62;
&#60;p&#62;$items[] = array(&#34;value&#34; =&#38;gt; $post-&#38;gt;post_title, &#34;text&#34; =&#38;gt; $post-&#38;gt;post_title);&#60;/p&#62;
&#60;p&#62;I want the value to be:  thePostTitle AND a Category. So the out put would be: Lowdown Brass band (post title) - Friday (taxonomy)&#60;/p&#62;
&#60;p&#62;Do this make sense? I'm trying to make a more descriptive title by pulling in custom taxonomies.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>MiikkaMakio on "Drop Down of Posts in Category?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/drop-down-of-posts-in-category#post-43404</link>
			<pubDate>Wed, 07 Dec 2011 23:02:26 +0000</pubDate>
			<dc:creator>MiikkaMakio</dc:creator>
			<guid isPermaLink="false">43404@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Ok..&#60;/p&#62;
&#60;p&#62;So I'm going to do it without the conditional logic. What would I need to add to get the dynamic population to work for the 'City'  drop down. If the City that a form user wants to select is not ready in the drop down list, he would be able to write to the 'City if not in the list' and next user of the form would see that one in the 'City' drop down. I tried to follow the guide, but didn't quite get how I should determine that it takes the text from the 'CIty if not in the list'.&#60;/p&#62;
&#60;p&#62;&#60;a href=&#34;http://www.vaihtoon.fi/WordPress&#34; rel=&#34;nofollow&#34;&#62;http://www.vaihtoon.fi/WordPress&#60;/a&#62;
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Carl Hancock on "Drop Down of Posts in Category?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/drop-down-of-posts-in-category#post-43239</link>
			<pubDate>Tue, 06 Dec 2011 16:37:05 +0000</pubDate>
			<dc:creator>Carl Hancock</dc:creator>
			<guid isPermaLink="false">43239@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;The situation is the built in conditional logic only works off of static values and doesn't currently take into account being triggered by dynamically populated fields.  This is a feature we'd like to tackle in the future but there have been higher priority features we have been working on.  &#60;/p&#62;
&#60;p&#62;It's one of many features we'd like to add and will eventually be added as we are constantly working in improving and enhancing Gravity Forms.&#60;/p&#62;
&#60;p&#62;The only way to do this now would be as a customization that would be fairly complex because you'd have to implement your own conditional logic as well as dynamically populate drop down fiels.  There isn't currently a tutorial on this type of complex customization.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>MiikkaMakio on "Drop Down of Posts in Category?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/drop-down-of-posts-in-category#post-43204</link>
			<pubDate>Tue, 06 Dec 2011 01:53:09 +0000</pubDate>
			<dc:creator>MiikkaMakio</dc:creator>
			<guid isPermaLink="false">43204@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Hey!&#60;/p&#62;
&#60;p&#62;What's the situation with dynamically populating drop downs AND combining it with conditional logic options?&#60;/p&#62;
&#60;p&#62;I would like to create a site where people:&#60;br /&#62;
Choose country (countries ready)&#60;br /&#62;
This opens new drop down 'University in Spain'  (i.e. if country=Spain)&#60;br /&#62;
Then there would be a text field where you could insert new university if it's not in the drop down list. And this entry would be in the drop down list (University in Spain) for next user who uses the form.&#60;/p&#62;
&#60;p&#62;So is there any way to do this?&#60;/p&#62;
&#60;p&#62;Form: &#60;a href=&#34;http://www.vaihtoon.fi/WordPress/share&#34; rel=&#34;nofollow&#34;&#62;http://www.vaihtoon.fi/WordPress/share&#60;/a&#62;
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Carl Hancock on "Drop Down of Posts in Category?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/drop-down-of-posts-in-category#post-30318</link>
			<pubDate>Mon, 18 Jul 2011 15:19:23 +0000</pubDate>
			<dc:creator>Carl Hancock</dc:creator>
			<guid isPermaLink="false">30318@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;You can dynamically populate a drop down field with anything you want, you  just need to know how to write the code to return the values you want... in this case you'd need to know how to query and return the items in the WP Menu.&#60;/p&#62;
&#60;p&#62;Here is a tutorial on how to dynamically populate a drop down:&#60;/p&#62;
&#60;p&#62;&#60;a href=&#34;http://www.gravityhelp.com/documentation/page/Dynamically_Populating_Drop_Down_Fields&#34; rel=&#34;nofollow&#34;&#62;http://www.gravityhelp.com/documentation/page/Dynamically_Populating_Drop_Down_Fields&#60;/a&#62;
&#60;/p&#62;</description>
		</item>
		<item>
			<title>creativitymill on "Drop Down of Posts in Category?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/drop-down-of-posts-in-category#post-30186</link>
			<pubDate>Sat, 16 Jul 2011 14:57:10 +0000</pubDate>
			<dc:creator>creativitymill</dc:creator>
			<guid isPermaLink="false">30186@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Is it possible to populate a drop-down using a wp_nav_menu? I'm building a site for a restaurant with 22 different locations, and one of the forms is a newsletter signup. I've got the locations list populating in various parts of the site from a WP Menu, and was wondering if I can use that to generate the drop-down, so they don't have to edit the list in multiple locations if there are changes.&#60;/p&#62;
&#60;p&#62;Thanks!
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Carl Hancock on "Drop Down of Posts in Category?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/drop-down-of-posts-in-category#post-26169</link>
			<pubDate>Mon, 23 May 2011 16:14:32 +0000</pubDate>
			<dc:creator>Carl Hancock</dc:creator>
			<guid isPermaLink="false">26169@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;As I mentioned, i'll have to discuss this with our lead developer.  It's my understanding that there is not, but we can look at it and see if there are any additional hooks we can add to make it so you can dynamically populate drop downs/checkbox/radio buttons AND have it reflected in conditional logic options.  He is currently traveling so I won't be able to discuss this with him until tomorrow.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Alan Villalobos on "Drop Down of Posts in Category?"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/drop-down-of-posts-in-category#post-26163</link>
			<pubDate>Mon, 23 May 2011 15:22:21 +0000</pubDate>
			<dc:creator>Alan Villalobos</dc:creator>
			<guid isPermaLink="false">26163@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I see.&#60;/p&#62;
&#60;p&#62;Is there a workaround you could suggest?&#60;/p&#62;
&#60;p&#62;Is there a way to populate something like a hidden field with code, and then drive the conditional logic off that?&#60;/p&#62;
&#60;p&#62;Or is there someway to show / hide fields dynamically with code hooks?&#60;/p&#62;
&#60;p&#62;Thanks again,&#60;/p&#62;
&#60;p&#62;Alan
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
