<?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: Random default value</title>
		<link>https://legacy.forums.gravityhelp.com/topic/random-default-value</link>
		<description>Gravity Support Forums Topic: Random default value</description>
		<language>en-US</language>
		<pubDate>Mon, 20 Apr 2026 00:56:03 +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/random-default-value" rel="self" type="application/rss+xml" />

		<item>
			<title>David Smith on "Random default value"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/random-default-value#post-67256</link>
			<pubDate>Fri, 20 Jul 2012 13:29:15 +0000</pubDate>
			<dc:creator>David Smith</dc:creator>
			<guid isPermaLink="false">67256@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Hi Scotti,&#60;/p&#62;
&#60;p&#62;This might be helpful to you: &#60;a href=&#34;http://gravitywiz.com/2012/07/20/random-fields-with-gravity-forms/&#34; rel=&#34;nofollow&#34;&#62;http://gravitywiz.com/2012/07/20/random-fields-with-gravity-forms/&#60;/a&#62;
&#60;/p&#62;</description>
		</item>
		<item>
			<title>David Peralty on "Random default value"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/random-default-value#post-65610</link>
			<pubDate>Tue, 10 Jul 2012 15:25:22 +0000</pubDate>
			<dc:creator>David Peralty</dc:creator>
			<guid isPermaLink="false">65610@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;You can't put that as the default value of the field from within the editor, but you could easily use one of our hooks to be able to pre-populate that field. Make sure the field can be pre-populated, and then look at the code we have for gform_pre_render.&#60;/p&#62;
&#60;p&#62;&#60;a href=&#34;http://www.gravityhelp.com/documentation/page/Gform_pre_render&#34; rel=&#34;nofollow&#34;&#62;http://www.gravityhelp.com/documentation/page/Gform_pre_render&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;As for the random questions and answers, you could then use the value in a hidden field set by your random call to determine which objects should be shown or hidden in Conditional Logic for your 40 questions. It wouldn't let you do things fully random, but it is a start.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>scottidesign on "Random default value"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/random-default-value#post-65596</link>
			<pubDate>Tue, 10 Jul 2012 14:16:27 +0000</pubDate>
			<dc:creator>scottidesign</dc:creator>
			<guid isPermaLink="false">65596@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I want to set a default value of a field to a random number, lets say range 1 to 4.&#60;/p&#62;
&#60;p&#62;Does Gravity Forms allow PHP inside the default value field?&#60;/p&#62;
&#60;p&#62;For instance &#38;lt;?php echo rand(1, 4); ?&#38;gt;&#60;/p&#62;
&#60;p&#62;If not, is there a way to random display a set of fields?&#60;/p&#62;
&#60;p&#62;For instance, I have 40 questions, and I only want 10 of those questions to randomly show to the user.&#60;/p&#62;
&#60;p&#62;What is the best way to do this?
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
