Changeset 7288
- Timestamp:
- 06/09/2018 03:56:16 AM (8 years ago)
- Location:
- sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-support
- Files:
-
- 3 edited
-
functions.php (modified) (2 diffs)
-
header.php (modified) (1 diff)
-
page-homepage.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-support/functions.php
r7136 r7288 137 137 */ 138 138 function wporg_get_global_header() { 139 $GLOBALS['pagetitle'] = wp_ title( '«', false, 'right' ) . ' ' . get_bloginfo( 'name');139 $GLOBALS['pagetitle'] = wp_get_document_title(); 140 140 require WPORGPATH . 'header.php'; 141 141 } … … 149 149 require WPORGPATH . 'footer.php'; 150 150 } 151 152 153 /** 154 * Append an optimized site name. 155 * 156 * @param array $title { 157 * The document title parts. 158 * 159 * @type string $title Title of the viewed page. 160 * @type string $page Optional. Page number if paginated. 161 * @type string $tagline Optional. Site description when on home page. 162 * @type string $site Optional. Site title when not on home page. 163 * } 164 * @return array Filtered title parts. 165 */ 166 function wporg_support_document_title( $title ) { 167 if ( is_front_page() ) { 168 $title['title'] = _x( 'Support', 'Site title', 'wporg-forums' ); 169 $title['tagline'] = __( 'WordPress.org', 'wporg-forums' ); 170 } else { 171 $title['site'] = __( 'WordPress.org', 'wporg-forums' ); 172 } 173 174 return $title; 175 } 176 add_filter( 'document_title_parts', 'wporg_support_document_title' ); 177 178 /** 179 * Set the separator for the document title. 180 * 181 * @return string Document title separator. 182 */ 183 function wporg_support_document_title_separator() { 184 return '|'; 185 } 186 add_filter( 'document_title_separator', 'wporg_support_document_title_separator' ); 151 187 152 188 /** -
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-support/header.php
r5297 r7288 29 29 <div class="site-branding"> 30 30 <?php if ( is_front_page() ) : ?> 31 <h1 class="site-title"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php _ex( ' Support', 'Site title', 'wporg-forums' ); ?></a></h1>31 <h1 class="site-title"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php _ex( 'WordPress Support', 'Site title', 'wporg-forums' ); ?></a></h1> 32 32 33 33 <p class="site-description"> 34 34 <?php 35 35 /* Translators: subhead */ 36 _e( 'We \'ve got a variety of resources to help you get the most out of WordPress.', 'wporg-forums' );36 _e( 'We’ve got a variety of resources to help you get the most out of WordPress.', 'wporg-forums' ); 37 37 ?> 38 38 </p> -
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-support/page-homepage.php
r5927 r7288 1 1 <?php 2 3 2 /** 4 3 * Template Name: bbPress - Support (Index) … … 7 6 * @subpackage Theme 8 7 */ 8 9 /** 10 * Adds a custom description meta tag. 11 */ 12 add_action( 'wp_head', function() { 13 printf( '<meta name="description" content="%s" />' . "\n", esc_attr__( 'Our community support articles are the best place to get the most out of WordPress. Learn how to set up your website, troubleshoot problems, customize your site, and more.', 'wporg-forums' ) ); 14 } ); 9 15 10 16 get_header(); ?>
Note: See TracChangeset
for help on using the changeset viewer.