Skip to content

Instantly share code, notes, and snippets.

@billerickson
Created June 6, 2018 18:55
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 billerickson/904be923e9f328793bd9c73f50eb6520 to your computer and use it in GitHub Desktop.
Save billerickson/904be923e9f328793bd9c73f50eb6520 to your computer and use it in GitHub Desktop.
<?php
/**
* Template Name: Plugins (CMB2)
*
* @package BE2018
* @author Bill Erickson
* @since 1.0.0
* @license GPL-2.0+
**/
// General functions used by all plugin templates
require get_template_directory() . '/inc/plugins-general.php';
/**
* Plugin Listing
*
*/
function ea_cmb2_fields_plugin_listing() {
$plugins = get_post_meta( get_the_ID(), 'be_plugins', true );
ea_plugins_listing( $plugins );
}
add_action( 'tha_content_loop', 'ea_cmb2_fields_plugin_listing' );
remove_action( 'tha_content_loop', 'ea_default_loop' );
// Build the page
require get_template_directory() . '/index.php';
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment