Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Gravity Wiz // Gravity Forms // Dynamic Population: Is Post Author?
/**
* Gravity Wiz // Gravity Forms // Dynamic Population: Is Post Author?
* http://gravitywiz.com/
*/
add_filter( 'gform_field_value_is_post_author', 'gw_dyn_pop_is_post_author' );
function gw_dyn_pop_is_post_author() {
global $post;
return $post ? get_current_user_id() == $post->post_author : false;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.