Advertisement
chrishajer

Delete last 4 of credit card field from database

Nov 26th, 2013
169
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.51 KB | None | 0 0
  1. <?php
  2. // originally http://pastie.org/8498705
  3. // target form id 66, change to your form id
  4. // set the priority on the call to 20 to make sure the payment gateway filters have all ran
  5. add_action("gform_after_submission_66", "clear_cc", 20, 2);
  6. function clear_cc($entry, $form){
  7.     //the credit card field on my form is field id 4, and the credit card number part of the complex field will be 1, so field 4.1, change to your field, but leave the ".1"
  8.     GFFormsModel::update_lead_field_value($form, $entry,"","","4.1","");
  9. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement