<?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: Programatically accessing decimal field values</title>
		<link>https://legacy.forums.gravityhelp.com/topic/programatically-accessing-decimal-field-values</link>
		<description>Gravity Support Forums Topic: Programatically accessing decimal field values</description>
		<language>en-US</language>
		<pubDate>Sun, 05 Apr 2026 02:15:16 +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/programatically-accessing-decimal-field-values" rel="self" type="application/rss+xml" />

		<item>
			<title>jkoschei89 on "Programatically accessing decimal field values"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/programatically-accessing-decimal-field-values#post-25875</link>
			<pubDate>Wed, 18 May 2011 21:07:50 +0000</pubDate>
			<dc:creator>jkoschei89</dc:creator>
			<guid isPermaLink="false">25875@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;It's all local at the moment, but if I can't solve it soon I'll put it online and send you the link. Thanks for your help!
&#60;/p&#62;</description>
		</item>
		<item>
			<title>David Smith on "Programatically accessing decimal field values"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/programatically-accessing-decimal-field-values#post-25874</link>
			<pubDate>Wed, 18 May 2011 21:06:32 +0000</pubDate>
			<dc:creator>David Smith</dc:creator>
			<guid isPermaLink="false">25874@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Any chance you could send a login to your WP admin and FTP to &#60;a href=&#34;mailto:david@rocketgenius.com&#34;&#62;david@rocketgenius.com&#60;/a&#62;? I'll take a look tomorrow morning for you.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>jkoschei89 on "Programatically accessing decimal field values"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/programatically-accessing-decimal-field-values#post-25870</link>
			<pubDate>Wed, 18 May 2011 19:52:22 +0000</pubDate>
			<dc:creator>jkoschei89</dc:creator>
			<guid isPermaLink="false">25870@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Hm -- same result. Your solution looks right, but out of all the float valued IDs, I'm still only getting the one at 7.5.&#60;/p&#62;
&#60;p&#62;The plot thickens - I just checked the default Gravity Forms Entries page, and the same thing happens. The values are intact in the database, they just can't be accessed.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>David Smith on "Programatically accessing decimal field values"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/programatically-accessing-decimal-field-values#post-25866</link>
			<pubDate>Wed, 18 May 2011 17:03:22 +0000</pubDate>
			<dc:creator>David Smith</dc:creator>
			<guid isPermaLink="false">25866@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Since you already have the lead (and all the lead values), you might be doing more than you need to. Here is a snippet that might be helpful. In order to get the float valued IDs, I cast them as a string before retrieving those IDs from the lead.&#60;/p&#62;
&#60;p&#62;&#60;a href=&#34;http://pastie.org/1923709&#34; rel=&#34;nofollow&#34;&#62;http://pastie.org/1923709&#60;/a&#62;
&#60;/p&#62;</description>
		</item>
		<item>
			<title>jkoschei89 on "Programatically accessing decimal field values"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/programatically-accessing-decimal-field-values#post-25852</link>
			<pubDate>Wed, 18 May 2011 13:52:53 +0000</pubDate>
			<dc:creator>jkoschei89</dc:creator>
			<guid isPermaLink="false">25852@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I'm struggling to word this in a way that makes sense, but here goes:&#60;/p&#62;
&#60;p&#62;I'm writing some code that loops through each entry and gathers the values stored in each field. This works perfectly for anything with a single value per field - inputs, dropdowns, etc. - but is showing some strange behavior on names, addresses, and other fields where the values are stored in multiple parts.&#60;/p&#62;
&#60;p&#62;For some reason, when I use RGFormsModel::get_field_value() on those items, only the values stored in numbers divisible by .5 are displayed. For instance, I have address data stored at 7.1, 7.2, 7.4, 7.4, 7.5, and 7.7. When I access the data, only the value stored at 7.5 comes up. I've tried several different methods of accessing the data, and the same thing happens each time.&#60;/p&#62;
&#60;p&#62;Here's the relevant code snippet:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;$leads = RGFormsModel::get_leads(1);
	foreach($leads as $lead)
	{
		echo &#38;#39;&#38;lt;tr&#38;gt;&#38;#39;;
		foreach($field_ids as $field_id)
		{
			$value = get_field_value($field_id, $lead[&#38;#39;id&#38;#39;]);
			if(!$value)
			{
				$field = RGFormsModel::get_field($form, $field_id);
				$value_list = RGFormsModel::get_field_value($field);
				$value = &#38;#39;&#38;#39;;
				foreach(array_keys($value_list) as $value_item) {
					$value .= get_field_value($value_item, $lead[&#38;#39;id&#38;#39;]).&#38;#39; &#38;#39;;
				}
			}

			echo &#38;#39;&#38;lt;td&#38;gt;&#38;#39;.$value.&#38;#39;&#38;lt;/td&#38;gt;&#38;#39;;
		}
		echo &#38;#39;&#38;lt;/tr&#38;gt;&#38;#39;;
	}&#60;/code&#62;&#60;/pre&#62;</description>
		</item>

	</channel>
</rss>
