Skip to content

Commit 993b64d

Browse files
committed
Fixed filter for admin_footer_text
1 parent 23842dc commit 993b64d

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

includes/admin/class-alnp-admin.php

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* Auto Load Next Post - Admin.
44
*
55
* @since 1.0.0
6-
* @version 1.5.5
6+
* @version 1.5.7
77
* @author Sébastien Dumont
88
* @category Admin
99
* @package Auto Load Next Post/Admin
@@ -24,7 +24,7 @@ class Auto_Load_Next_Post_Admin {
2424
*
2525
* @access public
2626
* @since 1.0.0
27-
* @version 1.4.10
27+
* @version 1.5.7
2828
*/
2929
public function __construct() {
3030
// Include classes.
@@ -40,10 +40,10 @@ public function __construct() {
4040
// Add settings page.
4141
add_action( 'admin_menu', array( $this, 'admin_menu' ), 9 );
4242

43-
// Filters
43+
// Filters plugin row and admin footer.
4444
add_filter( 'plugin_action_links_' . plugin_basename( AUTO_LOAD_NEXT_POST_FILE ), array( $this, 'plugin_action_links' ) );
4545
add_filter( 'plugin_row_meta', array( $this, 'plugin_row_meta'), 10, 3 );
46-
add_filter( 'admin_footer_text', array( $this, 'admin_footer_text' ) );
46+
add_filter( 'admin_footer_text', array( $this, 'admin_footer_text' ), 15, 1 );
4747
add_filter( 'update_footer', array( $this, 'update_footer'), 15 );
4848
} // END __construct()
4949

@@ -279,20 +279,20 @@ public function plugin_row_meta( $links, $file, $data ) {
279279
*
280280
* @access public
281281
* @since 1.0.0
282-
* @version 1.4.10
283-
* @param string $text
282+
* @version 1.5.7
283+
* @param string $text text to be rendered in the footer.
284284
* @return string $text
285285
*/
286286
public function admin_footer_text( $text ) {
287287
$current_screen = get_current_screen();
288288

289289
if ( isset( $current_screen->id ) && $current_screen->id == 'settings_page_auto-load-next-post-settings' ) {
290290
// Rating and Review
291-
return sprintf(
291+
$text = sprintf(
292292
/* translators: 1: Auto Load Next Post 2:: five stars */
293293
__( 'If you like %1$s, please leave a %2$s rating. A huge thank you in advance!', 'auto-load-next-post' ),
294294
sprintf( '<strong>%1$s</strong>', esc_html__( 'Auto Load Next Post', 'auto-load-next-post' ) ),
295-
'<a href="' . AUTO_LOAD_NEXT_POST_REVIEW_URL . '?rate=5#new-post" target="_blank" data-rated="' . esc_attr__( 'Thanks :)', 'auto-load-next-post' ) . '">&#9733;&#9733;&#9733;&#9733;&#9733;</a>'
295+
'<a href="' . AUTO_LOAD_NEXT_POST_REVIEW_URL . '?rate=5#new-post" target="_blank" aria-label="' . esc_attr__( 'five star', 'auto-load-next-post' ) . '" data-rated="' . esc_attr__( 'Thanks :)', 'auto-load-next-post' ) . '">&#9733;&#9733;&#9733;&#9733;&#9733;</a>'
296296
);
297297
}
298298

0 commit comments

Comments
 (0)