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.

Not save to database

  1. I have a customer that does not want the results of a form saved to the database, the information is sensitive, and as a result of compliance issues, they only want form results emailed. Is there a way to not store the data?

    Posted 13 years ago on Friday October 1, 2010 | Permalink
  2. They want to email sensitive data? That's not good unless you're encrypting the content.

    Posted 13 years ago on Friday October 1, 2010 | Permalink
  3. The issue is storing the data.. Please, I appreciate the reply, But am not looking to debate the customers need, just trying to get an answer to my question.

    Posted 13 years ago on Friday October 1, 2010 | Permalink
  4. @kbevinton This is possible and someone will be replying soon with how to do this and an example code snippet. This is a customization so keep in mind this isn't considered standard support but we will be glad to provide you with some example code once one of our developers is free to put it together.

    Posted 13 years ago on Friday October 1, 2010 | Permalink
  5. Hi Kbevington,

    Here's a bit of code that will remove the entry data after the form has been submitted:

    http://pastie.org/1194274

    The only customization you will need to make is to update the 1 in 'gform_post_submission_1' to the id of the form you wish to enable this functionality on. If you'd like this to apply to all forms on your site, remove the number and preceding underscore altogether like so, 'gform_post_submission'.

    Let me know if you have any questions! :)

    Posted 13 years ago on Friday October 1, 2010 | Permalink
  6. To clarify, you would take the code David has supplied and place it in your themes functions.php file.

    Posted 13 years ago on Friday October 1, 2010 | Permalink
  7. Adding this to bottom of functions.php and testing I get this message on submit:

    Fatal error: Call to undefined function print_rr() in /public_html/wp-content/themes/twentyten/functions.php on line 502

    and it has saved the info to the db too. Form id=1.

    Posted 13 years ago on Wednesday November 3, 2010 | Permalink
  8. changed instances of print_rr to print_r.

    Now it:

    -doesn't save a copy to the database (good)
    -is adding a number and the page content before the form sucessfully submitted message(bad) Any suggestions?

    Posted 13 years ago on Wednesday November 3, 2010 | Permalink
  9. gregreimer
    Member

    Could this be modified to delete only certain fields, like a credit card number?

    Posted 13 years ago on Thursday November 4, 2010 | Permalink
  10. Thank you for this! I realize that this is an old thread but I have a similar situation with a client who doesn't want to store form results in their database. I *really* want to have them use Gravity Forms because I think this plugin is the best available especially for content editors with no HTML knowledge. But if I couldn't resolve this, it would be a dealbreaker for the client and I would have to find another form plugin for them. Thank you again, so much, for providing this flexibility! Another reason why Gravity Forms and rocketgenius are the best!

    Posted 12 years ago on Monday September 12, 2011 | Permalink

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