?> " data-request="#new-metaplate-form"><?php _e('Add New', 'metaplate'); ?> </span> </h2> </div> <?php $metaplates = calderawp\metaplate\core\data::get_registry(); if (empty($metaplates)) { $metaplates = array(); } global $wpdb; foreach ($metaplates as $metaplate_id => $metaplate) { $metaplate = calderawp\metaplate\core\data::get_metaplate($metaplate['id']); if (isset($metaplate['content_type_specific']) && false == $metaplate['content_type_specific']) { $post_types = __('Non content type specific.', 'metaplate'); } elseif (!empty($metaplate['post_type'])) { $post_types = implode(', ', array_keys((array) $metaplate['post_type'])); } else { $post_types = __('Disabled. (Not setup for any post types)', 'metaplate'); } ?> <div class="metaplate-card-item" id="metaplate-<?php echo $metaplate['id']; ?> "> <span class="dashicons dashicons-media-code metaplate-card-icon"></span> <div class="metaplate-card-content">
/** * Get metaplate data by ID or slug * * @param string $id_or_slug * * @return array|bool Returns the array for the metaplate or false if not found. */ function caldera_metaplate_get_metastack($id_or_slug) { return calderawp\metaplate\core\data::get_metaplate($id_or_slug); }