Making WordPress.org

Changeset 13735


Ignore:
Timestamp:
05/20/2024 07:29:02 PM ( 4 months ago)
Author:
ryelle
Message:

wporg-plugins-2024: Use a rounded number for the plugins count in tagline.

See https://github.com/WordPress/wporg-theme-directory/issues/68#issuecomment -2115897450 , closes https://github.com/WordPress/wordpress.org/pull/321 .

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-plugins-2024/patterns/front-page-header.php

    r13437 r13735  
    six six  */
    seven seven
      eight $count = wp_count_posts( 'plugin' )->publish;
      nine $count = floor( $count / 1000 ) * 1000;
      ten $description = sprintf(
      eleven     /* Translators: Total number of plugins, rounded to thousands (ex, 12,000). */
      twelve     _n(
      thirteen         'Extend your WordPress experience! Browse over %s free plugin.',
      fourteen         'Extend your WordPress experience! Browse over %s free plugins.',
      fifteen         $count,
      sixteen         'wporg-themes'
      seventeen     ),
      eighteen     number_format_i18n( $count )
      nineteen );
    eight twenty ?>
    nine twenty-one
     
    twenty-one thirty-three
    twenty-two thirty-four         <!-- wp:paragraph {"style":{"typography":{"lineHeight":"2.3"}},"textColor":"white"} -->
    twenty-three           <p class="has-white-color has-text-color" style="line-height:2.3">
    twenty-four           <? php
    twenty-five               $plugin_count = wp_count_posts( 'plugin' )->publish;
    twenty-six               printf(
    twenty-seven                   /* Translators: Total number of plugins. */
    twenty-eight                   esc_html( _n( 'Extend your WordPress experience! Browse %s free plugin.', 'Extend your WordPress experience! Browse %s free plugins.', $plugin_count, 'wporg-plugins' ) ),
    twenty-nine                   esc_html( number_format_i18n( $plugin_count ) )
    thirty               );
    thirty-one               ?>
    thirty-two           </p>
      thirty-five         <p class="has-white-color has-text-color" style="line-height:2.3"><? php echo esc_html( $description ); ?></ p>
    thirty-three thirty-six         <!-- / wp:paragraph -->
    thirty-four thirty-seven     </div>
Note: See TracChangeset for help on using the changeset viewer.