A simple and efficient post like system for WordPress. View the demo.
Check out this post on Sven Hofmann's site for more information.
Originally, this system utilized Font Awesome for the heart and gear icons. The Font Awesome version is still available in the vendor folder for those who are already using Font Awesome in their theme.
- Add the CSS to your theme's main stylesheet.
- Add post-like.min.js to your theme's js folder (if it exists). If there is no js folder at your theme's root level, create one and add post-like.min.js to it.
- Add all the fonts to your theme's fonts folder (if it exists). If there is no fonts folder at your theme's root level, create one and add all the fonts to it.
- Add the contents of post-like.php to your theme's functions.php file.
- Implement the button by doing one of the following:
- Add the button function to your theme's single page template (typically content-single.php) — echo getPostLikeLink( get_the_ID() );
- Include the [jmliker] shortcode in your posts