WordPress.org

Ready to get started?Download WordPress

Forums

Gravity Forms Data Persistence Add-On
Clearing the Persistent Data (9 posts)

  1. kwirx
    Member
    Posted 1 year ago #

    After the user submits the information for this form, when the return to the form, the previous values are still in the form. How can I reset the form once it has been successfully submitted without the Data Persistence Add-On keeping the previous set?

    http://wordpress.org/extend/plugins/gravity-forms-data-persistence-add-on/

  2. opsec
    Member
    Posted 1 year ago #

    I'm having this same problem after clearing my cache in chrome the data disappears, until I login to the site again it's re-populated. Is there a way to permanently delete the persistent data if the user chooses?

    Thanks

  3. drew173
    Member
    Posted 1 year ago #

    It's funny, for me, I would want it to be the exact opposite - I am using gravity forms to have my clients (brides and grooms) fill out big pre-wedding forms that collect all kinds of information about them, the reception agenda, etc (I'm a Mobile DJ). So I specifically WANT this plugin to hang onto the data. It would be best if it were an admin setting - "clear persistence after successful submission."

  4. HCNadmin
    Member
    Posted 1 year ago #

    Has anyone found an answer for this? We have a form for first responders that will have confidential information. I want users to be able to come back to the form as many times as necessary to get it done but then clear the information after they submit. Thanks.

    http://www.harrisoncommunitynetwork.org/40-2/community-living/health-caresafety/safety/safety_hcn-activities/first-responder-information/

  5. opsec
    Member
    Posted 1 year ago #

    The only way to do so is manually from the database. If you don't know what you're doing it can screw up your WordPress install. This would be a useful feature to add, a checkbox the user can tick "delete my persistent data"

    You can contact Riz (the maker of this plugin) directly here:

    http://www.asthait.com/contact.aspx

    He does respond, however he is in Bangladesh so there's a time difference and I'm unsure of his current workload.

  6. HCNadmin
    Member
    Posted 1 year ago #

    Thanks. Obviously, I have very limited knowledge about what I'm doing, so I will leave hands off. Thanks for the contact info.

  7. bwhontwerpers
    Member
    Posted 1 year ago #

    I'm not sure, but this seems to be a bug inside the 'Enable multi entry from same user while form is persistent' functionality. In my opinion, the form should be cleared out when a user submits the form, so that a new entry can be made without using the old persistent data.

    The 'persistent_multipage_forms.php' file contains a specific function that does the job. Provided with the correct $lead_id, the function 'delete_entry_from_gf_tables' removes all persistant data from the database. Maybe we could access this function directly and force a cleanup during a gform_submission_hook of some sort.

    - Jelle

  8. berio
    Member
    Posted 1 year ago #

    This is what I did following bwhontwerpers road:

    Find the file persistent_multipage_forms.php and inside set_post_content() function find the line that says:
    update_option($entry_option_key, $entry['id']);

    and write just below it the following one:
    update_option($option_key, json_encode(''));

    it will clear all the user data related to the form.

  9. bwhontwerpers
    Member
    Posted 1 year ago #

    Thanks for the quick fix berio. All is good now, although I was hoping for a solution that didn't involve 'hacking' into the plugin source code. But still, it does the job, so thanks again!

    - Jelle

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic