Add related posts after content automatically, related posts by tags, full customize, easy to use.
Related Posts
Plugin features:
- Easy to use, just activate the plugin.
- Related posts after content automatically.
- Related posts by tags.
- Full customize.
- Filters ready (for custom wrap).
Live Demo
Usage
Download Related Posts Plugin, install it and activate it. Now plugin is ready, but if you want to customize, go to Plugins menu > Related Posts, you will find plugin options.
In your posts, use tags, for example: you have two posts about “Twitter”, enter “twitter” tag for your posts, will be display related posts in your twitter posts, you can using multi tags.
Example
This is post has “themes” tag, and this is post has “themes” tag.
Options
- In “Title” field, enter your title, default title is “Related Posts”.
- In “Title Heading” field, enter title heading, for example “h2”, default heading is “h4”.
- In “List Type” field, enter list type, for example “ol”, default list type is “ul”.
- In “Number Of Posts” field, enter number of related posts, default number is “5”.
Filters
To add custom wrap, use this filters:
function add_wrap_to_related_posts_before(){ return '<div class="my-custom-wrap">'; // start wrap } add_filter('alobaidi_related_posts_filter_wrap_before', 'add_wrap_to_related_posts_before'); function add_wrap_to_related_posts_after(){ return '</div>'; // end wrap } add_filter('alobaidi_related_posts_filter_wrap_after', 'add_wrap_to_related_posts_after');
CSS Classes
To customize the elements, use this css classes:
.alobaidi-related-posts-title{ /* title class */ }
.alobaidi-related-posts-list{ /* list class */ }