Exemple #1
0
 /**
  * Display admin page
  */
 public function display()
 {
     // Load options
     $options = WPSEO_News::get_options();
     // Admin header
     WPSEO_News_Wrappers::admin_header(true, 'yoast_wpseo_news_options', 'wpseo_news');
     // Introducten
     echo '<p>' . __('You will generally only need XML News sitemap when your website is included in Google News.', 'wordpress-seo-news') . '</p>';
     echo '<p>' . sprintf(__('You can find your news sitemap here: %1$sXML News sitemap%2$s', 'wordpress-seo-news'), "<a target='_blank' class='button-secondary' href='" . WPSEO_News::get_sitemap_name() . "'>", '</a>') . '</p>';
     // Google News Publication Name
     echo WPSEO_News_Wrappers::textinput('name', __('Google News Publication Name', 'wordpress-seo-news'));
     // Default Genre
     echo WPSEO_News_Wrappers::select('default_genre', __('Default Genre', 'wordpress-seo-news'), WPSEO_News::list_genres());
     // Default keywords
     $this->default_keywords();
     // Post Types to include in News Sitemap
     $this->include_post_types();
     // Post categories to exclude
     $this->excluded_post_categories();
     // Editors' Pick
     $this->editors_pick();
     // Admin footer
     WPSEO_News_Wrappers::admin_footer(true, false);
 }
 /**
  * The metaboxes to display and save for the tab
  *
  * @param string $post_type
  *
  * @return array $mbs
  */
 public function get_meta_boxes($post_type = 'post')
 {
     $mbs = array('newssitemap-exclude' => array('name' => 'newssitemap-exclude', 'type' => 'checkbox', 'std' => 'on', 'title' => __('Exclude from News Sitemap', 'wordpress-seo-news')), 'newssitemap-keywords' => array('name' => 'newssitemap-keywords', 'type' => 'text', 'std' => '', 'title' => __('Meta News Keywords', 'wordpress-seo-news'), 'description' => __('Comma separated list of the keywords this article aims at, use a maximum of 10 keywords.', 'wordpress-seo-news')), 'newssitemap-genre' => array('name' => 'newssitemap-genre', 'type' => 'multiselect', 'std' => isset($this->options['default_genre']) ? $this->options['default_genre'] : 'blog', 'title' => __('Google News Genre', 'wordpress-seo-news'), 'description' => __('Genre to show in Google News Sitemap.', 'wordpress-seo-news'), 'options' => WPSEO_News::list_genres(), 'serialized' => true), 'newssitemap-original' => array('name' => 'newssitemap-original', 'std' => '', 'type' => 'text', 'title' => __('Original Source', 'wordpress-seo-news'), 'description' => __('Is this article the original source of this news? If not, please enter the URL of the original source here. If there are multiple sources, please separate them by a pipe symbol: | .', 'wordpress-seo-news')), 'newssitemap-stocktickers' => array('name' => 'newssitemap-stocktickers', 'std' => '', 'type' => 'text', 'title' => __('Stock Tickers', 'wordpress-seo-news'), 'description' => __('A comma-separated list of up to 5 stock tickers of the companies, mutual funds, or other financial entities that are the main subject of the article. Each ticker must be prefixed by the name of its stock exchange, and must match its entry in Google Finance. For example, "NASDAQ:AMAT" (but not "NASD:AMAT"), or "BOM:500325" (but not "BOM:RIL").', 'wordpress-seo-news')), 'newssitemap-standout' => array('name' => 'newssitemap-standout', 'std' => '', 'type' => 'checkbox', 'title' => __('Standout', 'wordpress-seo-news'), 'description' => $this->standout_description()), 'newssitemap-editors-pick' => array('name' => 'newssitemap-editors-pick', 'std' => '', 'type' => 'checkbox', 'title' => __("Editors' Pick", 'wordpress-seo-news'), 'description' => __("Editors' Picks enables you to provide up to five links to original news content you believe represents your organization’s best journalistic work at any given moment, and potentially have it displayed on the Google News homepage or select section pages.", 'wordpress-seo-news')));
     return $mbs;
 }