In this blog article, we’ll explore the WordPress filters that allow you to override the reading time labels for the WP Astra theme. With these filters, you can set any text for singular and plural reading time, which is particularly useful if you want to offer your website in multiple languages or use a language other than English. Unfortunately, it’s not possible to translate these texts using standard WordPress methods. Therefore, these filters represent the best solution to solve this problem.
Singular (1 Minute Reading Time)
add_filter( 'astra_post_minute_of_reading_text', function() {
return __( 'minute of reading', 'astra-addon' );
});
Plural (Multiple Minutes Reading Time)
add_filter( 'astra_post_minutes_of_reading_text', function() {
return __( 'minutes of reading', 'astra-addon' );
});