next_posts_link_attributes WordPress Filter Hook
The next_posts_link_attributes hook allows you to add custom attributes to the next posts link. This can be useful for adding data- attributes for use with JavaScript, or for adding classes for use with CSS.
apply_filters( 'next_posts_link_attributes', string $attributes ) #
Filters the anchor tag attributes for the next posts page link.
Parameters
- $attributes
(string)Attributes for the anchor tag.
Source
Changelog
Version | Description |
---|---|
2.7.0 | Introduced. |