Skip to content

Instantly share code, notes, and snippets.

@braddalton
Last active October 22, 2015 14:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save braddalton/a9020317a03c786f865d to your computer and use it in GitHub Desktop.
Save braddalton/a9020317a03c786f865d to your computer and use it in GitHub Desktop.
Add Meta Box in Genesis http://wp.me/p1lTu0-g6V
function genesis_audio_file_box() {
wp_nonce_field( 'genesis_audio_file_save', 'genesis_audio_file_nonce' );
?>
<p><label for="genesis_audio_file" class="screen-reader-text"><strong><?php _e( 'Post-specific Audio', 'genesis' ); ?></strong></label></p>
<p><textarea class="widefat" rows="3" cols="4" name="genesis_audio_file[audio_link]" id="genesis_audio_file"><?php echo esc_url( genesis_get_custom_field( 'audio_link' ) ); ?></textarea></p>
<p><?php printf( __( 'Click Media > Library & find the URL to the audio file to copy & paste in this box.', 'genesis' ) ); ?></p>
<?php
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment