Get the metaplates for the post

@return    array    active metaplates for this post type
558705
public static function get_active_metaplates( ) {

		global $post;

		if( empty( $post ) ){ return; } // no post - return

		// GET METAPLATEs
		$metaplates = self::get_registry();
		$meta_stack = array();
		if ( is_array( $metaplates ) ) {
			foreach ( $metaplates as $metaplate_try ) {
				$is_plate = self::get_metaplate( $metaplate_try['id'] );
				if ( ! empty( $is_plate['post_type'][ $post->post_type ] ) ) {
					switch ( $is_plate['page_type'] ) {
						case 'single':
							if ( is_single() || is_page() ) {
								$meta_stack[] = $is_plate;
							}
							break;
						case 'archive':
							if ( ( is_archive() || is_front_page() ) && ( ! is_page() || ! is_single() ) ) {
								$meta_stack[] = $is_plate;
							}
							break;
						default:
							$meta_stack[] = $is_plate;
							break;
					}
				}
			}
		}

		return $meta_stack;

	}
806353
public function getTemplateInheritors()
    {
        $templateInheritors = [];
        foreach ($this->inheritors as $inheritor) {
            if ($inheritor instanceof self) {
                $templateInheritors[] = $inheritor;
            }
        }

        return $templateInheritors;
    }
990775
public function getTemplateDirs()
    {
        $config = \OxidEsales\Eshop\Core\Registry::getConfig();

        // buffer for CE (main) edition templates
        $mainTemplatesDirectory = $config->getTemplateDir($this->isAdmin());

        // main templates directory has not much priority anymore
        $this->setTemplateDir($mainTemplatesDirectory);

        // out directory can have templates too
        if (!$this->isAdmin()) {
            $this->setTemplateDir($this->addActiveThemeId($config->getOutDir(true)));
        }

        return $this->_aTemplateDir;
    }
1065402
public function buildTemplate()
    {
        if (!empty($this->template)) {
            return $this->template;
        }

        $actions = [];
        foreach ($this->actionBuilders as $actionBuilder) {
            $actions[] = $actionBuilder->buildTemplateAction();
        }

        $this->template = [
            'type' => TemplateType::BUTTONS,
            'text' => $this->text,
            'actions' => $actions,
        ];

        if ($this->title) {
            $this->template['title'] = $this->title;
        }

        if ($this->thumbnailImageUrl) {
            $this->template['thumbnailImageUrl'] = $this->thumbnailImageUrl;
        }

        if ($this->imageAspectRatio) {
            $this->template['imageAspectRatio'] = $this->imageAspectRatio;
        }

        if ($this->imageSize) {
            $this->template['imageSize'] = $this->imageSize;
        }

        if ($this->imageBackgroundColor) {
            $this->template['imageBackgroundColor'] = $this->imageBackgroundColor;
        }

        if ($this->defaultAction) {
            $this->template['defaultAction'] = $this->defaultAction->buildTemplateAction();
        }

        return $this->template;
    }
106007
public function getPageMetas()
    {
        if (!$this->parser) {
            return;
        }

        $nodes = $this->parser->find('meta');

        $metas = array();

        foreach ($nodes as $node) {
            if ($node->hasAttribute('name')) {
                $metas[ $node->getAttribute('name') ] = $node->getAttribute('content');
            } elseif ($node->hasAttribute('property')) {
                $metas[ $node->getAttribute('property') ] = $node->getAttribute('content');
            }
        }

        return $metas;
    }
305175
public function metasArray()
	{
		$metas = array();
		
		foreach ($this->metas as $meta) {
			if (!isset($meta->pivot)) {
				continue;
			}
			
			$metas[$meta->name] = $meta->pivot->value;
		}
		
		return $metas;
	}
257984
public function getTemplateVariables()
	{
		return array_merge($this->template_variables, [
			'options' => $this->getOptions(),
			'column' => $this->getColumn(),
			'key' => $this->getKey(),
			'status' => $this,
		]);
	}
1113337
public function getSeoTags() {
        if($this->owner->seo) {
            $seo = $this->owner->seo->attributes;
            return array_filter(array_intersect_key($seo, array_flip(['meta_title', 'meta_keywords', 'meta_description'])));
        } else {
            return [];
        }
    }
988269
public function getTemplatesForWebPreView()
    {
        $templates = array();
        $templates = $this->addTemplate($templates, 'Reset Passwort Email', AzineTemplateProvider::FOS_USER_PWD_RESETTING_TEMPLATE);
        $templates = $this->addTemplate($templates, 'Account activation', AzineTemplateProvider::FOS_USER_REGISTRATION_TEMPLATE);
        // override this method to add your own templates
        // $templates =$this->addTemplate($templates, "Some other mail",	ExampleTemplateProvider::SOME_OTHER_MAIL_TEMPLATE);
        // $templates =$this->addTemplate($templates, "VIP Infos",	ExampleTemplateProvider::VIP_INFO_MAIL_TEMPLATE);
        return $templates;
    }
535583
public static function get_top_level_templates()
	{

		$ss_templates_array = array();
		$current_theme_path = THEMES_PATH.'/'.Config::inst()->get('SSViewer', 'theme');

		//theme directories to search
		$search_dir_array = array(
			MAINTENANCE_MODE_PATH.'/templates',
			$current_theme_path.'/templates'
		);

		foreach ($search_dir_array as $directory) {

			//Get all the SS templates in the directory
			foreach (glob("{$directory}/*.ss") as $template_path) {

				//get the template name from the path excluding the ".ss" extension
				$template = basename($template_path, '.ss');

				//Add the key=>value pair to the ss_template_array
				$ss_templates_array[$template] = $template;
			}

		}

		return $ss_templates_array;

	}
393989
public function metaBoxTemplateAreas()
    {
	global $wp_registered_sidebars;
	global $modularityOptions;

	usort($wp_registered_sidebars, function ($a, $b) {
	    return $a['name'] > $b['name'];
	});

	$coreTemplates = \Modularity\Helper\Wp::getCoreTemplates();
	$coreTemplates = apply_filters('Modularity/CoreTemplatesInTheme', $coreTemplates);
	$customTemplates = get_page_templates();
	$templates = array_merge($coreTemplates, $customTemplates);

	include MODULARITY_TEMPLATE_PATH . 'options/partials/modularity-template-areas.php';
    }
1018891
public function getMetaHeaders()
    {
        if ($this->offsetExists('meta') && is_array($this->meta)) {
            $meta = $this->meta;
        } else {
            $meta = [];
        }
        if (!array_key_exists('Content-Type', $meta)) {
            $meta['Content-Type'] = 'text/html;charset=UTF-8';
        }

        // Remove null/empty values, this allow you to remove the Content-Type by making it empty.
        return array_filter($meta);
    }
591287
protected function _getTemplate()
    {
        if (is_null($this->_template)) {
            foreach ($this->_map as $method => $className) {
                if ($this->_sql instanceof $className) {
                    $this->_template = $this->$method();
                    break;
                }
            }
        }
        return $this->_template;
    }
1288084
public function get_template_titles() {

		static $template_titles;

		if ( empty( $template_titles ) ) {
			$all_templates = (array) pods_api()->load_templates( array() );

			$template_titles = array();

			foreach ( $all_templates as $template ) {
				$template_titles[] = $template['name'];
			}
		}

		return $template_titles;

	}
1361557
public function getPostedValues()
    {
        $result = $_POST;
        $result = $this->alterPostedValues($result);
        unset($result[static::Meta]);
        return $result;
    }
538561
public function metaData()
    {
        add_action('admin_footer', function () {
            global $pagenow;

            if (!current_user_can('edit_posts') || !current_user_can('edit_pages') || $pagenow != 'post.php') {
                return;
            }

            global $post;
            $metakeys = \Municipio\Helper\Post::getPostMetaKeys($post->ID);

            echo '<script>
                    var metadata_button = [
            ';

            $count = 0;
            foreach ($metakeys as $key => $value) {
                echo "{text: '{$value->meta_key}', value: '[meta key=\"{$value->meta_key}\"]'},";
                $count++;
            }

            echo '];</script>';
        });

        add_filter('mce_external_plugins', function ($plugins) {
            global $pagenow;

            if (!current_user_can('edit_posts') || !current_user_can('edit_pages') || $pagenow != 'post.php') {
                return $plugins;
            }

            $plugins['metadata'] = get_template_directory_uri() . '/assets/dist/' . \Municipio\Helper\CacheBust::name('js/mce-metadata.js');
            return $plugins;
        });

        add_filter('mce_buttons_2', function ($buttons) {
            global $pagenow;

            if (!current_user_can('edit_posts') || !current_user_can('edit_pages') || $pagenow != 'post.php') {
                return $buttons;
            }

            array_splice($buttons, 2, 0, array('metadata'));
            return $buttons;
        });
    }
728461
public function getFormTemplate()
    {
        if (null === $this->formTemplate) {
            $template = rtrim($this->getTemplatePrefix(), '/') . '/' . $this->getFormSuffix();
            $this->setFormTemplate($template);
        }

        return $this->formTemplate;
    }