Changeset 5413
- Timestamp:
- 04/25/2017 04:09:12 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/shortcodes/class-developers.php
r5393 r5413 55 55 ] ); 56 56 57 $locales_list = implode( ', ', array_map( function( $site ) use ( $slug, $locale_names ) { 58 return sprintf( '<a href="%1$s">%2$s</a>', esc_url( "{$site->home}/plugins/{$slug}/" ), $locale_names[ $site->locale ] ); 59 }, $sites ) ); 57 if ( $sites ) { 58 $locales_list = implode( ', ', array_map( function( $site ) use ( $slug, $locale_names ) { 59 return sprintf( '<a href="%1$s">%2$s</a>', esc_url( "{$site->home}/plugins/{$slug}/" ), $locale_names[ $site->locale ] ); 60 }, $sites ) ); 60 61 61 $locales_count = count( $sites );62 $locales_count = count( $sites ); 62 63 63 if ( 1 === $locales_count ) { 64 if ( 1 === $locales_count ) { 65 $output .= sprintf( 66 /* translators: 1: plugin name, 2: locale name */ 67 __( '“%1$s” has been translated into %2$s.' ), 68 $title, 69 $locales_list 70 ) . ' '; 71 } else { 72 $output .= sprintf( 73 /* translators: 1: plugin name, 2: number of locales, 3: list of locales */ 74 _n( 75 '“%1$s” has been translated into these %2$d locales: %3$s.', 76 '“%1$s” has been translated into these %2$d locales: %3$s.', 77 $locales_count 78 ), 79 $title, 80 $locales_count, 81 $locales_list 82 ) . ' '; 83 } 84 64 85 $output .= sprintf( 65 /* translators: 1: plugin name, 2: locale name */ 66 __( '“%1$s” has been translated into %2$s.' ), 67 $title, 68 $locales_list 69 ) . ' '; 70 } else { 71 $output .= sprintf( 72 /* translators: 1: plugin name, 2: number of locales, 3: list of locales */ 73 _n( 74 '“%1$s” has been translated into these %2$d locales: %3$s.', 75 '“%1$s” has been translated into these %2$d locales: %3$s.', 76 $locales_count 77 ), 78 $title, 79 $locales_count, 80 $locales_list 81 ) . ' '; 86 /* translators: URL to translator view */ 87 __( 'Thank you to <a href="%s">the translators</a> for their contributions.', 'wporg-plugins' ), 88 esc_url( "https://translate.wordpress.org/projects/wp-plugins/{$slug}/contributors" ) 89 ); 90 $output .= '</p>'; 82 91 } 83 84 $output .= sprintf(85 /* translators: URL to translator view */86 __( 'Thank you to <a href="%s">the translators</a> for their contributions.', 'wporg-plugins' ),87 esc_url( "https://translate.wordpress.org/projects/wp-plugins/{$slug}/contributors" )88 );89 $output .= '</p>';90 92 } 91 93
Note: See TracChangeset
for help on using the changeset viewer.