WP Favorite Posts

  • Favorite list is empty.
FavoriteLoadingClear favorites

Your favorite posts saved to your browsers cookies. If you clear cookies also favorite posts will be deleted.

I made a plugin named as WP Favorite Posts. This plugin allows visitors to mark a post as favorite. There is no register requirement because this plugin saves data to cookies. Furthermore it can save data to database if user logged in. The user can see his/her favorite posts list from “Your Favorites” page which you created.

DEMO See it in action

Don’t forget to donate

[paypal-donation purpose=”WP Favorite Posts” reference=”nxsn.com”]

Installation

It’s very easy;

  1. Download the WP Favorite Posts plugin.
  2. Unzip into your /wp-content/plugins/ directory.
  3. Activate the plugin through the ‘Plugins’ menu in WordPress
  4. Place <?php if (function_exists('wpfp_link')) { wpfp_link(); } ?> in your single.php or index.php template file. Then favorite this post link will appear in all posts.
  5. Create a page e.g. “Your Favorites” and insert text into content section. This page will contain users favorite posts.
  6. That’s it :)

Widget

And there is a widget and template tag for listing most favorited posts. You can go widgets page for using widget. Template tag’s usage;

<h2>Most Favorited Posts</h2>
<?php wpfp_list_most_favorited(10); ?>

The parameter for limiting post count of list. Default value is 5 posts.

Bugs & Appreciations

You can report bugs or write your appreciations by using comments of this post. Also you can see the source code and the ChangeLog. Thanks for using my plugin!

New Feature Request or Need Modification

If you have a feature request or need modification which is urgent for you, contact me. We can make a deal.

Did you like plugin ?

If you like my plugin, i’ll appreciate it if you buy me a coffe or beer! I would love if you write a blog post/tweet etc about my plugin.
[paypal-donation purpose=”WP Favorite Posts” reference=”nxsn.com”]

Some Details

Show Link In Post Content

You can show Add/Remove Favorites Link into post wherever you want with writing FavoriteLoadingAdd to favorites into post content while HTML mode.

Change Template Of “Your Favorites” Page

(version 1.4) You can change “your favorites” page’s templates easily.

First copy wpfp-page-template.php from plugin’s directory to your theme’s directory. Then make template changes (add thumbnail image, make what you want).

If you make something wrong just delete or rename wpfp-page-template.php from your theme’s directory and page’s view will be turn back to basic view.

Who Uses This Plugin ? (DEMO)

http://www.nefisyemektarifleri.com/tarif-defterim/

http://www.hdvideoclip.com/my-playlist

http://www.android-software.fr/mes-favoris

http://www.beckermanphoto.com/your-favorite-prints

396 thoughts on “WP Favorite Posts

  1. bren

    sorry for all these posts!

    for settings input such as the ‘Text for favorites are empty’
    an input like ‘Your favorites are empty. You can add pages and posts here by clicking the “Add to favorites” link at the bottom of each page’
    is rendering with slashes -> \”Add to favorites\”
    same for html such as Add to favorites is being rendered without parsing the HTML.

    thanks again for a great plugin – looking forward to the updates

    Reply
  2. bren

    more ideas again – hope you don’t mind!

    ability to merge cookie favorites with logged in favorites would be nice so that if you add a favorite before loggin in you can merge the cookie data to the database saved list.

    currently they are independant so the following things happen
    – if you add a favorite as a cookie then log in, the page will be shown with the other database entries but will of course be lost if you clear cookies
    – if you add a favorite as a cookie then log in, if you already existed as a database favorite then two instances will be displayed

    thanks again

    Reply
  3. Strand Sardinien

    Hi there, thanks for that plugin, it works great.
    But is there a way to have more than one User Favourite`s widgets?
    I use different sidebars for different categories and more than one instance!

    Thanks for your help

    Reply
  4. helen

    This plugin is beautiful!
    But, if i want to display the favorite posts in author page (author.php), what can i do?
    I mean to display authomatically the favorite post of EACH author of the blog (not only mine).
    thanks

    Reply
  5. jamy

    hi
    when i install the plugin i have an error

    Fatal error: Cannot redeclare wpfp_widget_view() (previously declared in /homez.146/boumelit/www/wordpress/wp-content/plugins/wp-favorite-posts/wpfp-widgets.php:3) in /homez.146/boumelit/www/wordpress/wp-content/plugins/wp-favorite-posts/wpfp-widgets.php on line 3

    and when you will update the last favorite post ?

    thanks

    Reply
  6. Luke Stephenson

    Hi, thanks for the great plugin.

    I would love to modify the page which lists the favorite posts. At the moment it only displays the post title. I need each favorite item to display the featured image and the value of a custom field called “location”. This would make the plugin even more amazing!!! Please could you supply the code?

    Reply
  7. Luke

    Hi Huseyin,

    Great Plugin! I really would like to style the list of favorites . Please could you provide the code for adding the post featured image and the value of a custom field called “location”??

    Thanks a lot!

    Reply
  8. BAC

    Loving wpfp Huseyin.

    Is there a simple way to get count of “Favorited Posts” for the current user [via the cookie]?

    I would like to display the count next to a link to the favorited posts page e.g favorited posts (3) etc.

    I’d then have to AJAXify this as using W3 total cache Page Cache.

    Cheers
    B

    Reply
  9. ygertz

    Hi!

    First of all, thank you for the plugin!

    I can add the widget once but my theme has 4 different sidebars. How can I add the plugin in all my sidebars?

    How could I get logs for the favorited post added/removed?

    Thanx for the support!

    Reply
  10. Jesper

    Hi,

    thanks for a great plugin.
    I would need to insert the favorite list in some sort of contact form or email. I would like the possibility to let the visitor send me their list. Do you know any way to do that..?

    Thanks again for a awsome plugin.

    Reply
  11. jaapo

    hi, like the plugin but i like to know what the php code is for; {{wp-favorite-posts}} so i can put in the author.php…

    Reply
  12. Wendy

    Great plugin. I had someone customize the look of it for me. I have two issues. Could you fix these for my site? I would pay you. Readers tell me there is a limit of what can be listed in the favorites list. After a certain amount has been added it drops some off. Is there a way to make the list unlimited? Also, sometimes the whole list gets wiped out for no reason. I warn readers not to delete their cookies but they say they aren’t and it is still happening. Do you know why?

    Reply
  13. Wendy

    Not sure my message came through. I use your plugin and love it. I have over 300 a day who use it and this helps me to keep more of my readers on my site. I keep hearing from them on the same issues though and I don’t know how to solve it.

    They go to their favorite list and it is empty. They do not delete cookies.
    The Favorites list seems to have a limit and it drops some off without warning.

    Can these things be fixed? I would be willing to pay for the help.

    Reply
  14. Stixman

    Hi all, it is possible to show the category and the image of the post in the favorite page and order by ASC ?
    like : Actiongames : [ Image ] Black Ops Korean

    Thx

    Reply
  15. Charlie

    Hey, love the plugin. Great work!
    However, I want the icon (heart etc) to be clickable instead of the text, so when you click the heart it lights up from grey to color.

    How can I do this?

    Thanks!

    Reply
  16. Ciprian

    Since I just did this, I might as well help Charlie out. Select “no image” and add html in the “Text for add link” option and do the same for the remove link.

    Now for my question: I want to show the from latest to oldest favorite posts on the Favorites page. So the latest favorited post should be on top. How can I do that? Should be a user option. A clickable title.

    Thank you!

    Reply
    1. Huseyin Berberoglu Post author

      @Ciprian with latest verison of plugin this feature is default. You should update your plugin.

      Reply
  17. Michel Fortin

    Bug report: in wp-favorite.posts.php line 417, you need to add a backslash before the ? query as the WP output will be wrong (it issues a double quote instead of single).

    Reply
  18. Michel Fortin

    Yes, when you don’t add /? it turns the single quote ‘ into a double ” in my wordpress installations. Since it starts with a double quote ” and ends with a single quote ‘ it creates havoc for installations with redirect plugins that force a trailing slash on categories, for example.

    Here’s before I added the slash on line 417:

    <a id="rem_4080" class="wpfp-link remove-parent" href="?wpfpaction=remove&page=1&postid=3640' title='X' rel='nofollow'>X</a>

    And now, AFTER I added the fix…

    Reply
  19. Michel Fortin

    Let me try this again. Before the fix…

    href=”?wpfpaction=remove&page=1&postid=3640′

    After I added the fix, it added the domain in the link and a double quote to properly close it.

    href=”http://mydomain.com/?wpfpaction=remove&page=1&postid=3640″

    Reply
  20. ku

    hello, if not is_user_logged_in I want to let it to Login page , how to do this ? who can help me ??? please!

    Reply
  21. Florence

    Great work, thanks!
    I do have one suggestion.
    I’d love to see a favorite posts plugin that wil show the users a list of their favorite posts.
    Are you planning on doing anything like that with this plugin or are you not changing it any more?

    Reply
  22. Jens

    Hello and thank you for a great plugin!
    You say that you add the code to single.php, but is it also possible to add it to index.php, to show the favorite link on all posts on the homepage?

    Thank you!
    // Jens.

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *