PLEASE NOTE: These forums are no longer utilized and are provided as an archive for informational purposes only. All support issues will be handled via email using our support ticket system. For more detailed information on this change, please see this blog post.

How to retrieve entry data?

  1. Sorry if I'm missing this somewhere, I'm new to Gravity Forms -- is there a function available for retrieving data previously added from a form, something like gform_get_entry($form_id, $entry_id), with an array returned containing data from the specified entry?

    It looks like maybe I can save all entries as posts, and then use the WP custom field functions to get at the data, but I'd rather access the data directly if possible.

    Thanks!

    David

    Posted 13 years ago on Wednesday July 20, 2011 | Permalink
  2. I have forwarded this to our lead developer who will take a look and suggest ways of doing this. I'm not sure of specific helper functions for accessing entry data.

    The ability to access and display entry data on the front end is something i'd like to focus on with the v1.7 release. later this year. The v1.6 release is currently in development and it's too late to add extensive entry display functionality to this release.

    Posted 13 years ago on Thursday July 21, 2011 | Permalink
  3. To get one entry, you can use the following call. It will return an Entry Object.

    RGFormsModel::get_lead($entry_id);

    To get a list of entries for a specific form, you can use the following call. It will return an array of Entry Objects

    RGFormsModel::get_leads($form_id)

    Note: This call has some extra parameters that lets you specify sorting, searching, number of entries to return, etc... We don't have a full documentation on this method, so you will have to inspect the function definition (forms_model.php) in order to find out about all the parameters.

    Posted 13 years ago on Thursday July 21, 2011 | Permalink
  4. Thanks so much for the quick reply, it works perfectly, exactly what I needed!

    David

    Posted 13 years ago on Thursday July 21, 2011 | Permalink

This topic has been resolved and has been closed to new replies.