/** * Returns the Content score element for the adminbar. * * @return string */ function wpseo_tax_adminbar_content_score() { $rating = 0; if (is_tax() || is_category() || is_tag()) { $rating = WPSEO_Taxonomy_Meta::get_meta_without_term('content_score'); } return wpseo_adminbar_score($rating); }
/** * @return bool */ private function taxonomy_image_output() { foreach (array('twitter-image', 'opengraph-image') as $tag) { $img = WPSEO_Taxonomy_Meta::get_meta_without_term($tag); if ($img !== '') { $this->image_output($img); return true; } } return false; }
/** * Check if taxonomy has an image and add this image */ private function get_opengraph_image_taxonomy() { if (($ogimg = WPSEO_Taxonomy_Meta::get_meta_without_term('opengraph-image')) !== '') { $this->add_image($ogimg); } }
/** * Returns the meta value for the given $meta_key. * * @param string $meta_key The target key that will be fetched. * * @return string */ private function get_meta_value($meta_key) { if (is_singular()) { return WPSEO_Meta::get_value($meta_key); } if (is_category() || is_tag() || is_tax()) { return WPSEO_Taxonomy_Meta::get_meta_without_term($meta_key); } return ''; }