Changeset 14441
- Timestamp:
- 04/29/2025 04:23:40 PM (7 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/photo-directory/inc/admin.php
r14426 r14441 1175 1175 1176 1176 $author = get_user_by( 'id', $post->post_author ); 1177 $p hotos_count = User::count_published_photos( $author->ID );1177 $published_count = User::count_published_photos( $author->ID ); 1178 1178 $account_created = explode( ' ', $author->user_registered )[0]; 1179 1179 ?> … … 1207 1207 printf( 1208 1208 __( 'Published photos: <strong>%s</strong>', 'wporg-photos' ), 1209 ( 0 === $p hotos_count )1210 ? $p hotos_count1211 : sprintf( '<a href="%s">%s</a>', get_author_posts_url( $author->ID ), $photos_count )1209 ( 0 === $published_count ) 1210 ? $published_count 1211 : sprintf( '<a href="%s">%s</a>', esc_url( get_author_posts_url( $author->ID ) ), $published_count ) 1212 1212 ); 1213 1213 ?></li> … … 1307 1307 1308 1308 echo '<p>'; 1309 /* translators: %s: Rejection rate as a percentage. */ 1310 printf( __( 'Total rejection rate: %s', 'wporg-photos'), '<strong>' . round( ( $total_rejections / ( $photos_count + $total_rejections ) ) * 100, 2 ) .'%</strong>' ); 1309 $total_count = $published_count + $total_rejections; 1310 $rejection_rate = $total_count 1311 ? round( ( $total_rejections / $total_count ) * 100, 2 ) 1312 : 0; 1313 1314 printf( 1315 /* translators: %s: Rejection rate as a percentage. */ 1316 __( 'Total rejection rate: %s', 'wporg-photos'), 1317 '<strong>' . $rejection_rate .'%</strong>' 1318 ); 1311 1319 echo "</p>\n"; 1312 1320
Note: See TracChangeset
for help on using the changeset viewer.