<?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: Conditional Confirmation</title>
		<link>https://legacy.forums.gravityhelp.com/topic/conditional-confirmation</link>
		<description>Gravity Support Forums Topic: Conditional Confirmation</description>
		<language>en-US</language>
		<pubDate>Thu, 23 Apr 2026 19:53:42 +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/conditional-confirmation" rel="self" type="application/rss+xml" />

		<item>
			<title>David Peralty on "Conditional Confirmation"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/conditional-confirmation#post-248167</link>
			<pubDate>Sat, 11 May 2013 14:53:59 +0000</pubDate>
			<dc:creator>David Peralty</dc:creator>
			<guid isPermaLink="false">248167@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Have you tried our Quiz Add-on? It might be a shortcut to what you want to do...
&#60;/p&#62;</description>
		</item>
		<item>
			<title>stature on "Conditional Confirmation"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/conditional-confirmation#post-244585</link>
			<pubDate>Thu, 09 May 2013 11:55:33 +0000</pubDate>
			<dc:creator>stature</dc:creator>
			<guid isPermaLink="false">244585@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Any help available? Please and thanks :-)
&#60;/p&#62;</description>
		</item>
		<item>
			<title>stature on "Conditional Confirmation"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/conditional-confirmation#post-242729</link>
			<pubDate>Wed, 08 May 2013 10:28:46 +0000</pubDate>
			<dc:creator>stature</dc:creator>
			<guid isPermaLink="false">242729@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I'm trying to call the field ID and associated value with a IF statement, and not quite getting it.&#60;/p&#62;
&#60;p&#62;How can I call a specific field ID and Value?&#60;br /&#62;
Replacing the ID and VALUE is not working for me: &#60;code&#62;$field[&#38;#39;ID&#38;#39;]=&#38;#39;VALUE&#38;#39;&#60;/code&#62;&#60;/p&#62;
&#60;p&#62;Where would I place the corrected code in the example below to have two separate confirmation messages? One if value = 1 and another if value = 2.&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;$_POST[&#38;#39;input_25&#38;#39;] = $score;
        switch($score) {
                // my &#38;quot;admin only&#38;quot; Rating field to hold the display message based on the score in input_24
                case 0:
                case 1:
                case 2:
                case 3:
                case 4:
                case 5:
                        $_POST[&#38;#39;input_24&#38;#39;] = &#38;#39;5 or fewer correct answers: You\&#38;#39;re a complacent leader who ignores changes in the environment.&#38;#39;;&#60;/code&#62;&#60;/pre&#62;</description>
		</item>
		<item>
			<title>stature on "Conditional Confirmation"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/conditional-confirmation#post-234301</link>
			<pubDate>Thu, 02 May 2013 21:41:36 +0000</pubDate>
			<dc:creator>stature</dc:creator>
			<guid isPermaLink="false">234301@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;It's been a week without a response - should I restructure my question? Hoping to get any help before the weekend!! Thanks to anyone who replies :-)
&#60;/p&#62;</description>
		</item>
		<item>
			<title>stature on "Conditional Confirmation"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/conditional-confirmation#post-231438</link>
			<pubDate>Tue, 30 Apr 2013 21:10:49 +0000</pubDate>
			<dc:creator>stature</dc:creator>
			<guid isPermaLink="false">231438@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Bump to the top - any help?
&#60;/p&#62;</description>
		</item>
		<item>
			<title>stature on "Conditional Confirmation"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/conditional-confirmation#post-224181</link>
			<pubDate>Thu, 25 Apr 2013 15:14:03 +0000</pubDate>
			<dc:creator>stature</dc:creator>
			<guid isPermaLink="false">224181@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Basically what I want to do is this:&#60;/p&#62;
&#60;p&#62;IF question#1 is NO (value = 0), AND score totals 6 to 18 THEN show Confirmation#1&#60;br /&#62;
IF question#1 is YES (value = 1), AND score totals 7 to 18 THEN show Confirmation #2&#60;br /&#62;
IF question#1 is NO (value = 0), AND score totals 19 to 29 THEN show Confirmation#3&#60;br /&#62;
IF question#1 is YES (value = 1), AND score totals 19 to 29 THEN show Confirmation #4&#60;br /&#62;
IF question#1 is NO (value = 0), AND score totals 30 to 41 THEN show Confirmation#5&#60;br /&#62;
IF question#1 is YES (value = 1), AND score totals 30 to 42 THEN show Confirmation #6&#60;/p&#62;
&#60;p&#62;I believe it should be a simple solution to include in my code example about the first case of each.&#60;br /&#62;
If someone could help with a general example for one instance I can apply to the rest of them.&#60;/p&#62;
&#60;p&#62;Thanks again for any assistance!
&#60;/p&#62;</description>
		</item>
		<item>
			<title>stature on "Conditional Confirmation"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/conditional-confirmation#post-224094</link>
			<pubDate>Thu, 25 Apr 2013 13:02:36 +0000</pubDate>
			<dc:creator>stature</dc:creator>
			<guid isPermaLink="false">224094@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Hello, I have created a quiz with scores calculation and several confirmation messages using the instruction from &#60;a href=&#34;http://www.gravityhelp.com/forums/topic/mathematics-to-gravity-forms&#34; rel=&#34;nofollow&#34;&#62;http://www.gravityhelp.com/forums/topic/mathematics-to-gravity-forms&#60;/a&#62;.&#60;/p&#62;
&#60;p&#62;My first quiz question is a Yes or No (with values 1 and 0). I have six total confirmation messages to include, 3 for scores IF the first question is YES and 3 IF the first question is NO.  My code is shown below, which currently includes the 3 confirmations for YES, I would like to add a condition here, and then use the same condition for NO and add the 3 confirmations for NO.&#60;/p&#62;
&#60;p&#62;Any help would be greatly appreciated.&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;add_action(&#38;#39;gform_pre_submission&#38;#39;, &#38;#39;ch_total_quiz_values&#38;#39;);
function ch_total_quiz_values ($form) {
        // change the number 2 here to your form ID
        // if this is not form 2, don&#38;#39;t do any processing
        if($form[&#38;#39;id&#38;#39;] != 2)
                return $form;

        // otherwise ...
        $score = 0;
        // my radio button inputs are numbered 1 to 20.  Change the beginning
        // and ending number in this loop to match your actual input numbers
        for($i=1; $i&#38;lt;=14; $i++) {
                // add the value of the $_POST value for input 1 to input 20
                $input  = &#38;#39;input_&#38;#39; . $i;
                $score += rgpost($input);
        }
        // update the hidden &#38;#39;Score&#38;#39; field with our calculated score
        $_POST[&#38;#39;input_25&#38;#39;] = $score;
        switch($score) {
                // my &#38;quot;admin only&#38;quot; Rating field to hold the display message based on the score in input_24
                case 7:
                case 8:
                case 9:
                case 10:
                case 11:
                case 12:
                case 13:
                case 14:
                case 15:
                case 16:
                case 17:
                case 18:
                        $_POST[&#38;#39;input_24&#38;#39;] = &#38;#39;Response Here&#38;#39;;
                        break;
                case 19:
                case 20:
                case 21:
                case 22:
                case 23:
                case 24:
                case 25:
                case 26:
                case 27:
                case 28:
                case 29:
                        $_POST[&#38;#39;input_24&#38;#39;] = &#38;#39;Response Here.&#38;#39;;
                        break;
                case 30:
                case 31:
                case 32:
                case 33:
                case 34:
                case 35:
                case 36:
                case 37:
                case 38:
                case 39:
                case 40:
                case 41:
                case 42:
                        $_POST[&#38;#39;input_24&#38;#39;] = &#38;#39;Response Here&#38;#39;;
                        break;
        }
        return $form;
}&#60;/code&#62;&#60;/pre&#62;</description>
		</item>

	</channel>
</rss>
