Created
February 28, 2014 03:52
-
-
Save mikeselander/9264892 to your computer and use it in GitHub Desktop.
Get data out of a Gravity Form with gform_after_submission
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Get an auction id & info from Gravity Forms ID8 | |
* | |
* @since 0.1.0 | |
* | |
*/ | |
add_action('gform_after_submission_8', 'ps_add_bid_card_from_form', 10, 2); // _8 means we're only grabbing data when the form ID8 is submitted | |
function ps_add_bid_card_from_form($entry, $form) { | |
// Get these two fields from fields ID2 & ID3 | |
$auction_id = $entry['3']; | |
$info = $entry['2']; | |
// Insert our resulting info into the custom table | |
bid_cards_insert_log( $auction_id, $info ); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment