Changeset 2998
- Timestamp:
- 04/22/2016 06:17:23 AM (10 years ago)
- Location:
- sites/trunk/wordpress.org/public_html/wp-content
- Files:
-
- 3 edited
-
plugins/plugin-directory/admin/list-table/class-plugin-posts.php (modified) (1 diff)
-
plugins/plugin-directory/class-plugin-directory.php (modified) (1 diff)
-
themes/pub/wporg-plugins/plugin-card.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/admin/list-table/class-plugin-posts.php
r2994 r2998 159 159 */ 160 160 public function column_rating( $post ) { 161 $rating = (string) get_post_meta( $post->ID, 'avg_rating', true ); 162 if ( ! empty( $rating ) && function_exists( 'wporg_get_dashicons_stars' ) ) { 163 echo wporg_get_dashicons_stars( $rating / 20 ); 161 if ( function_exists( 'wporg_get_dashicons_stars' ) ) { 162 echo wporg_get_dashicons_stars( get_post_meta( $post->ID, 'rating', true ) ); 164 163 } 165 164 } -
sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/class-plugin-directory.php
r2996 r2998 433 433 return $single ? $count : array( $count ); 434 434 break; 435 case 'rating': 436 $post = get_post( $object_id ); 437 // The WordPress.org global ratings functions 438 if ( ! function_exists( 'wporg_get_rating_avg' ) ) { 439 break; 440 } 441 $rating = wporg_get_rating_avg( 'plugin', $post->post_name ); 442 443 return $single ? $rating : array( $rating ); 444 break; 435 445 } 436 446 return $value; -
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-plugins/plugin-card.php
r2612 r2998 15 15 16 16 <div class="plugin-card-bottom"> 17 <!-- <div class="vers column-rating"> 18 <div class='wporg-ratings' title='4 out of 5 stars' style='color:#ffb900;'><span class="dashicons dashicons-star-filled"></span><span class="dashicons dashicons-star-filled"></span><span class="dashicons dashicons-star-filled"></span><span class="dashicons dashicons-star-filled"></span><span class="dashicons dashicons-star-empty"></span></div><span class="num-ratings" title="Rating based on 813 reviews">(813)</span> 19 </div> --> 17 <div class="vers column-rating"> 18 <?php 19 if ( function_exists( 'wporg_get_dashicons_stars' ) ) { 20 echo wporg_get_dashicons_stars( get_post_meta( $post->ID, 'rating', true ) ); 21 } 22 ?> 23 </div> 20 24 <div class="column-updated"> 21 25 <strong><?php _e( 'Last Updated:', 'wporg-plugins' ); ?></strong> <?php echo wporg_plugins_template_last_updated(); ?>
Note: See TracChangeset
for help on using the changeset viewer.