Load Options from another form

I am trying to use data stored in one form in a second form for notification purposes. For Example:

I have two forms: Property and Survey

Property.Address
Property.owner_name
Property.owner_email
Property.owner_mobile

and
Survey.ID
Survey.question1
Survey.question2
Survey.question3
etc.

When I load Form Survey
I would like a drop down populated with Property.Address values.
Then the rest of the form will be a bunch of Generic yes/no questions, text field, photo upload, etc.

THEN when the form is submitted, I want to send an email to Property.owner_email and text to Property.owner_mobile.

Now, I am not a developer, by no stretch, and have recently moved over from form-i-dable to take advantage of workflow and a few other things…

Thanks in advance for any help in this regard.

Hi Gene !

I might have a solution for you, I will run a quick test when I get the chance and get back to you later today.

Unless anyone else has a simpler solution for Gene … ?

Cheers,
-JAS

1 Like

Hi again Gene,

I do need some additional info on your requirements, please LMK:

  1. When you mention “data stored in one form” is this referring to entry data captured from a form submission made by another user in the past, or by the same user interacting with the Survey form during the same session as the interaction with submitting the Property form ?

  2. When you mention a “drop down” are you referencing a GF “Drop Down” field ?

Cheers,
-JAS

Hey JAS

Thank you for looking at this!!

  1. I am referring to entry data captured from a form submission in the past by another (or the same) user.

  2. Yes, referring to a GF “Drop Down” field.

Greets again,

I believe you’ll be needing at least some amount of custom coding, either PHP or Javascript, depending on your Dev’s preference.

So functionally, your custom code will be supplied with a target “Entry ID” by some means (like a query string param from a link, or a field value of a radio button, etc).

That code would “fetch” the Entry Object (either from the front-end Javascript or a back-end filter hook) - here are some examples:


Then on your Survey form, you would pre-populate the drop-down field using the fetched entry data, which would render for the web user with the acquired data.

I hope this is helpful :slight_smile:

Maybe someone else more experienced with GF knows some simple tricks or other approaches, feel free to chime in. I’m still learning myself !

Cheers,
-JAS

I’ve approached this in other cases, by sending entry data from the first form (Property) to the metadata of a custom post type, then querying the post type in order to fill the drop down on the second form (Survey). The Advanced Post Creation add-on might be helpful for this. I’ve also made good use of ACF for such needs.

I prefer this approach, because I like to utilize the forms more for only receiving and processing data (like a survey that is received and distributed) and the native WP post types for longer term storage of content (like the properties that will be needed for future user).

It does take a good deal of customization to put in place.

2 Likes

Greetings Joshua

Thank you for sharing your very innovative approach to this use case, I had never considered this solution as a possible option for supporting the archiving and retrival of entry data.

It is very tempting to consider implementing this as a 3rd data persistence option for my new “sticky field sharing” plug-in module currently in beta testing.

Do let me know if you’re interested in doing any OpenSource collaboration :slight_smile:

Cheers,
-JAS

Ref: github.com/jasbits

Hey Gene, if you’re looking for easiest, code-less solution for this, try Gravity Forms Populate Anything. Populating entries as choices and customizing which entry data to populate/display is this plugin’s bread and butter. Here’s an example of what your Drop Down’s settings might look like:

It also supports populating posts and post data as well if you liked Joshua’s suggestion.

2 Likes

I’ve not tried this perk, yet, but it looks so powerful!

1 Like