Skip to content

Instantly share code, notes, and snippets.

@jamigibbs
Created March 10, 2015 15:03
Show Gist options
  • Save jamigibbs/d0e52d16b9b2888d4908 to your computer and use it in GitHub Desktop.
Save jamigibbs/d0e52d16b9b2888d4908 to your computer and use it in GitHub Desktop.
function custom_field() {
global $post;
$url = get_post_meta( $post->ID, 'hero_style', true );
if ( ! empty( $url ) ) {
echo 'My Button';
}
}
add_filter( 'field', 'custom_field' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment