Changeset 9215
- Timestamp:
- 10/21/2019 03:45:34 AM (5 years ago)
- Location:
- sites/trunk/wordpress.org/public_html/wp-content/themes/pub
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-main/inc/page-meta-descriptions.php
r9192 r9215 27 27 } ); 28 28 29 $ locale_native_name = $GLOBALS['rosetta']->rosetta->glotpress_locale->native_name;29 $site_title = isset( $GLOBALS['wporg_global_header_options']['rosetta_title'] ) ? $GLOBALS['wporg_global_header_options']['rosetta_title'] : 'WordPress.org'; 30 30 return array( 31 31 'og:type' => 'website', 32 'og:title' => __( 'Blog Tool, Publishing Platform, and CMS - WordPress', 'wporg' ),32 'og:title' => __( 'Blog Tool, Publishing Platform, and CMS', 'wporg' ) . " - {$site_title}", 33 33 'og:description' => __( 'Open source software which you can use to easily create a beautiful website, blog, or app.', 'wporg' ), 34 34 'description' => __( 'Open source software which you can use to easily create a beautiful website, blog, or app.', 'wporg' ), 35 35 'og:url' => home_url( '/' ), 36 /* translators: %s - The Locale native name. */ 37 'og:site_name' => sprintf( __( 'WordPress - %s', 'wporg' ), $locale_native_name ), 36 'og:site_name' => $site_title, 38 37 'og:image' => 'https://s.w.org/images/home/screen-themes.png?3', 39 38 'og:locale' => get_locale(), … … 360 359 add_filter( 'the_title', __NAMESPACE__ . '\custom_page_title', 10, 2 ); 361 360 add_filter( 'single_post_title', __NAMESPACE__ . '\custom_page_title', 10, 2 ); 361 362 /** 363 * Set the document title on the front page. 364 */ 365 function document_title_parts( $title ) { 366 if ( isset( $title['site'] ) || is_front_page() ) { 367 $title['site'] = 'WordPress.org'; // Rosetta will replace as needed. 368 } 369 370 if ( is_front_page() ) { 371 $title['title'] = __( 'Blog Tool, Publishing Platform, and CMS', 'wporg' ); 372 } 373 374 return $title; 375 } 376 add_filter( 'document_title_parts', __NAMESPACE__ . '\document_title_parts' ); -
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg/functions.php
r9180 r9215 72 72 $GLOBALS['pagetitle'] = wp_get_document_title(); 73 73 } 74 add_action( ' template_redirect', __NAMESPACE__ . '\set_document_title');74 add_action( 'get_header', __NAMESPACE__ . '\set_document_title', 10 ); 75 75 76 76 /**
Note: See TracChangeset
for help on using the changeset viewer.