I have a custom post_type called, "lessons" which has meta fields that I populate with a gravity form.
I then have a "duplicate" of the form that loads on a separate page and dynamically populates the content with the meta information and is supposed to let people update the post.
I have a gform_after_submission hook to update the meta data, but because it's a custom post_type it's not working.
Here's what I have for the function to update the meta...
function gf_edit_plans( $entry, $form ) {
global $post;
$monday_lesson = $_POST['20'];
update_post_meta($postID, 'monday_lesson', $monday_lesson );
}
add_action( 'gform_after_submission_10', 'gf_edit_plans', 10, 2 );
Any ideas?
I've been racking my brain on this one for hours!!
Thanks.