Favoriting Posts In WordPress

WPBeginner has published an article that explains how they used the WP Favorite Posts plugin to give one of their clients a “personalized library” for their users which allowed them to favorite videos that they could watch repeatedly. In the article, they also explain how to use the plugin to provide that same personalized experience for your own site so that registered users or non-registered users could favorite specific posts that they could access later. It’s a cool plugin but upon reading the directions on how to display the favorite option within specific pages or posts, I was sent back into time because in order to accomplish that task, you need to add specific code to certain template files such as page.php, single.php, etc. I thought that practice of adding plugin functionality was gone but I guess not.


5 responses to “Favoriting Posts In WordPress”

  1. A simple add_action() hook would easily remove the need to hard code things into the theme files. Not sure why the plugin author doesn’t suggest this or better yet add the add_action() code into the plugin themselves.

    Anyways looks like a neat plugin.

  2. Updating WordPress would possibly overwrite any changes you make to your files also I believe. Then you would have to remember where to re-add that code. This could be a bad idea if you’re running with several plugins and start changing files by hand. I’m not speaking as a professional but I believe it would be best if any changes to files should be left inside the templates of a Child Theme

  3. On occasion, we’ve used WP Favorite Posts on client sites and our own ventures…mostly on sites using WordPress as a CMS. While we have used the php code with child themes, our preference is to use the plugin’s shortcode (also noted in the article) which gives more flexibility on placement within a page and is not theme centric.

    Since WPBeginner didn’t note the client site, as a demo/reference you can check out one use of WP Favorite Posts at http://newsfeedgadget.com, our “companion” reference venture for news readers/social magazines/iGoogle gadgets. The home page (i.e., MyNFG) acts as a personal favorites page and most content pages can be favorited (i.e., Add to MyNFG).


Subscribe Via Email

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

%d bloggers like this: