Making WordPress.org

Changeset 13733


Ignore:
Timestamp:
05/20/2024 12:18:05 AM ( 4 weeks ago)
Author:
dufresnesteven
Message:

wporg-plugins-2024: Update query total to show category for search results.

Fixes: https://github.com/WordPress/wordpress.org/issues/308
Props: ndiego, ryelle, fcoveram, joen

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-plugins-2024/inc/block-config.php

    r13693 r13733  
    two hundred and twenty-five two hundred and twenty-five     }
    two hundred and twenty-six two hundred and twenty-six
      two hundred and twenty-seven     $plugin_business_model = get_query_var( 'plugin_business_model' );
      two hundred and twenty-eight     if ( $plugin_business_model ) {
      two hundred and twenty-nine         $term_name = '';
      two hundred and thirty
      two hundred and thirty-one         if ( 'community' === $plugin_business_model ) {
      two hundred and thirty-two             $term_name = __( 'community', 'wporg-plugins' );
      two hundred and thirty-three         } elseif ( 'commercial' === $plugin_business_model ) {
      two hundred and thirty-four             $term_name = __( 'commercial', 'wporg-plugins' );
      two hundred and thirty-five         }
      two hundred and thirty-six
      two hundred and thirty-seven         return sprintf(
      two hundred and thirty-eight             /* Translators: %1$: Number of plugins, %2$s: Plugin category  */
      two hundred and thirty-nine             _n( '%1$s %2$s plugin', '%1$s %2$s plugins', $count, 'wporg-plugins' ),
      two hundred and forty             number_format_i18n( $count ),
      two hundred and forty-one             $term_name
      two hundred and forty-two         );
      two hundred and forty-three     }
      two hundred and forty-four
    two hundred and twenty-seven two hundred and forty-five     return _n( '%s plugin', '%s plugins', $count, 'wporg-plugins' );
    two hundred and twenty-eight two hundred and forty-six }
Note: See TracChangeset for help on using the changeset viewer.