Changeset 2376 for sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-showcase/functions.php
- Timestamp:
- 01/26/2016 11:41:27 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-showcase/functions.php
r2077 r2376 70 70 global $post; 71 71 72 echo '<h4> Flavor</h4>73 72 echo '<h4>' . __( 'Flavor', 'wporg-showcase' ). '</h4>'; 73 echo '<ul id="flavors">'; 74 74 75 75 $flavors = array( 'WordPress.org', 'WordPress.com', 'WordPress.com VIP', 'WordPress MS' ); … … 84 84 85 85 if ( in_category( 'BuddyPress' ) ) { 86 echo '<li class="flavor-used"><img src="' . get_template_directory_uri() . '/images/flavor-bp.png" /> BuddyPress</li>';87 } else { 88 echo '<li><img src="' . get_template_directory_uri() . '/images/flavor-bp2.png" /> BuddyPress</li>';86 echo '<li class="flavor-used"><img src="' . get_template_directory_uri() . '/images/flavor-bp.png" /> ' . __( 'BuddyPress', 'wporg-showcase' ). '</li>'; 87 } else { 88 echo '<li><img src="' . get_template_directory_uri() . '/images/flavor-bp2.png" /> ' . __( 'BuddyPress', 'wporg-showcase' ). '</li>'; 89 89 } 90 90 … … 94 94 function blockquote_style( $content ) { 95 95 if ( is_single() ) 96 $content = str_replace( '</blockquote>', '<cite> Source:<a href="http://' . get_site_domain( false, false ) . '">' . get_site_domain( false, false, true ) . '</a></cite><div class="clear"></div></blockquote>', $content );96 $content = str_replace( '</blockquote>', '<cite>' . __( 'Source:', 'wporg-showcase' ). ' <a href="http://' . get_site_domain( false, false ) . '">' . get_site_domain( false, false, true ) . '</a></cite><div class="clear"></div></blockquote>', $content ); 97 97 98 98 return $content; … … 120 120 $tags = get_terms( 'post_tag', $args ); 121 121 122 $out = '<h4> Browse Popular Tags</h4>';122 $out = '<h4>' . __( 'Browse Popular Tags', 'wporg-showcase' ). '</h4>'; 123 123 $out .= '<ul class="submenu wpsc-popular-tags">'; 124 124 … … 139 139 function breadcrumb() { ?> 140 140 141 <h3><a href="<?php echo home_url( '/' ); ?>" title=" Showcase">Showcase</a>141 <h3><a href="<?php echo home_url( '/' ); ?>" title="<?php esc_attr_e( 'Showcase', 'wporg-showcase' ); ?>"><?php _e( 'Showcase', 'wporg-showcase' ); ?></a> 142 142 143 143 <?php if ( is_search() ) : ?> 144 » Search for: <?php the_search_query(); ?>144 <?php printf( __( '» Search for: %s', 'wporg-showcase' ), get_search_query() ); ?> 145 145 <?php elseif ( strstr( $_SERVER['REQUEST_URI'], '/showcase/archives' ) ) : ?> 146 » Archives146 <?php _e( '» Archives', 'wporg-showcase' ); ?> 147 147 <?php else : ?> 148 148 <?php if ( is_category() ) : ?> 149 » Flavor149 <?php _e( '» Flavor', 'wporg-showcase' ); ?> 150 150 <?php elseif ( is_tag() ) : ?> 151 » Tag151 <?php _e( '» Tag', 'wporg-showcase' ); ?> 152 152 <?php endif; // is_category ?> 153 153 154 » <?php echo wp_get_document_title(); ?>154 <?php printf( __( '» %s', 'wporg-showcase' ), wp_get_document_title() ); ?> 155 155 <?php endif; // is_search ?> 156 156 … … 161 161 function sc_feed_author( $author ) { 162 162 if ( is_feed() ) 163 $author = 'WordPress Showcase';163 $author = _x( 'WordPress Showcase', 'Feed Author', 'wporg-showcase' ); 164 164 165 165 return $author; … … 175 175 foreach ( $posttags as $tag ) { 176 176 if ( $tag->count > 1 && !is_tag($tag->slug) ) { 177 $tag_link = '<a href="' . get_term_link($tag, 'post_tag') . '" rel="tag">' . $tag->name . ' (' . $tag->count . ')</a>';177 $tag_link = '<a href="' . get_term_link($tag, 'post_tag') . '" rel="tag">' . sprintf( _x( '%1$s (%2$s)', 'Tag name (tag count)', 'wporg-showcase' ), $tag->name, $tag->count ) . '</a>'; 178 178 } else { 179 179 $tag_link = $tag->name; … … 249 249 } elseif ( is_category() ) { 250 250 // Prepend 'Flavor: ' to category document titles. 251 $parts['title'] = 'Flavor: ' . $parts['title'];251 $parts['title'] = sprintf( __( 'Flavor: %s', 'wporg-showcase' ) . $parts['title'] ); 252 252 } elseif ( is_tag() ) { 253 253 // Prepend 'Tag: ' to tag document titles. 254 $parts['title'] = 'Tag: ' . $parts['title'];254 $parts['title'] = sprintf( __( 'Tag: %s', 'wporg-showcase' ) . $parts['title'] ); 255 255 } 256 256
Note: See TracChangeset
for help on using the changeset viewer.