<?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: Accessing product prices in gform_pre_submission</title>
		<link>https://legacy.forums.gravityhelp.com/topic/accessing-product-prices-in-gform_pre_submission</link>
		<description>Gravity Support Forums Topic: Accessing product prices in gform_pre_submission</description>
		<language>en-US</language>
		<pubDate>Mon, 20 Apr 2026 04:54:33 +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/accessing-product-prices-in-gform_pre_submission" rel="self" type="application/rss+xml" />

		<item>
			<title>Dana Cobb on "Accessing product prices in gform_pre_submission"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/accessing-product-prices-in-gform_pre_submission#post-44578</link>
			<pubDate>Tue, 20 Dec 2011 17:55:44 +0000</pubDate>
			<dc:creator>Dana Cobb</dc:creator>
			<guid isPermaLink="false">44578@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Yes, the total price is cumulative across all pages. Unfortunately, there isn't any easy way to get the total for each page. Using the $_POST information for the products/options is the only way to get a total per page.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>anniengo on "Accessing product prices in gform_pre_submission"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/accessing-product-prices-in-gform_pre_submission#post-44289</link>
			<pubDate>Fri, 16 Dec 2011 20:28:20 +0000</pubDate>
			<dc:creator>anniengo</dc:creator>
			<guid isPermaLink="false">44289@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Thanks for the response Dana! So do I understand that there's not a more direct way to get the option price?&#60;/p&#62;
&#60;p&#62;The form has 5 pages, one for each weekday. I need the total for Mondays (page 1), Tuesdays (page 2), etc. I was thinking the &#34;total&#34; field was a cumulative total. Is there a way to get the total for each page?
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Dana Cobb on "Accessing product prices in gform_pre_submission"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/accessing-product-prices-in-gform_pre_submission#post-43956</link>
			<pubDate>Tue, 13 Dec 2011 17:17:41 +0000</pubDate>
			<dc:creator>Dana Cobb</dc:creator>
			<guid isPermaLink="false">43956@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Hi, anniengo,&#60;/p&#62;
&#60;p&#62;I may not be understanding your request, but the pricing information is all available in $_POST for you to grab out.  You mentioned the price was included with the product name, but that is the price for the OPTION field associated to a product.  &#60;/p&#62;
&#60;p&#62;For each of the product fields there will be 3 (2 if using a separate quantity field) pieces of information in $POST for a product field. For instance, if my field is id 10, then input_10_1 is the product name, input_10_2 is the base price, and input_10_3 is the quantity (if your product field includes the quantity field with it). So you would need to get the price of the product, price of the option (which is what you are doing in your example) and multiply that  times the quantity. If using a separate quantity field then you would need to grab out the qty from the separate field associated to your product field.&#60;/p&#62;
&#60;p&#62;If you need the amount of all products on the page, then using the Total field is the best thing to use, but I understood your question to be in regards to only getting the prices for some of the products.&#60;/p&#62;
&#60;p&#62;Let me know if you have any questions about this.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>anniengo on "Accessing product prices in gform_pre_submission"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/accessing-product-prices-in-gform_pre_submission#post-43408</link>
			<pubDate>Thu, 08 Dec 2011 00:27:49 +0000</pubDate>
			<dc:creator>anniengo</dc:creator>
			<guid isPermaLink="false">43408@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Well I found one way to do it... The product name itself includes the price (eg. &#34;Sandwich &#124; 7.50&#34;), and I had stripped that off to make it look &#34;cleaner&#34;. So I changed it to strip off the price:&#60;/p&#62;
&#60;p&#62;$prod = $_POST[&#34;input_5&#34;];&#60;br /&#62;
$prodE = explode(&#34;&#124;&#34;, $prod,2); // breaks apart the product into 2 parts, separated by &#34;&#124;&#34;&#60;br /&#62;
$price =  $prodE[1]; // the 2nd part is the price&#60;/p&#62;
&#60;p&#62;Of course I'd appreciate learning a simpler way if anyone knows how :)
&#60;/p&#62;</description>
		</item>
		<item>
			<title>anniengo on "Accessing product prices in gform_pre_submission"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/accessing-product-prices-in-gform_pre_submission#post-43407</link>
			<pubDate>Wed, 07 Dec 2011 23:38:40 +0000</pubDate>
			<dc:creator>anniengo</dc:creator>
			<guid isPermaLink="false">43407@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Hi...&#60;/p&#62;
&#60;p&#62;I need to add up the prices for a subset of products. My hook to gform_pre_submission is able to concatenate strings of selected options, but I can't for the life of me get to the product prices. It looks like all the field object pricing properties can be manipulated before displaying the form, but how can I add prices based on the user selections?&#60;/p&#62;
&#60;p&#62;Thanks...
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
