WP Favorite Posts Plugin
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. Visitor can see his/her favorite posts list from “Favorites” page which you created.
Installation is very easy;
- Download the WP Favorite Posts plugin.
- Unzip into your
/wp-content/plugins/directory. - Activate the plugin through the ‘Plugins’ menu in WordPress
- Place
<?php if (function_exists('wpfp_link')) { wpfp_link(); } ?>in your single.php template file. Then favorite this post link will appear in all posts. - Create a page e.g. “Your Favorites” and insert
{{wp-favorite-posts}}text into content section. This page will contain users favorite posts. - That’s it
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.
You can report bugs or make feature requests by using comments of this post. Also you can see the source code. Thanks for using my plugin!
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.
@Justin Young I don’t have much time these days, sorry for latency.
Firstly, thanks for donation.
You can do it with this way;
Go Plugins > Editor
Find this line and remove it.
echo ” < a href=’”.get_permalink($post_id).”‘ title=’”. $p->post_title .”‘>” . $p->post_title . “</a> “;
Then add this line instead deleted line
echo $p->post_content;
Save file.
The images will shown in “favorites” page.
Huseyin Berberoglu | blog - WP Favorite Posts 1.3 Released !
31 May 09 at 12:32
[...] WP Favorite Posts [...]
WordPress Plugin Releases for 06/02 | Weblog Tools Collection
2 Jun 09 at 21:43
[...] WP Favorite Posts [...]
WordPress Plugin Releases for 06/02 | BlogBroker24-7
2 Jun 09 at 22:16
I am using the DynaBlue 1.0 theme with Wordpress 2.7.1 I have the Favourited Posts widget working, and the Favourites list, but not the link in the posts.
I have added to my single.php template file, but the link does not appear in any of my posts. I have tried moving it around in the single.php file, to no avail. Any thoughts?
Douglas Hill
3 Jun 09 at 01:19
[...] WP Favorite Posts [...]
WordPress Plugin Releases for 06/02 | BloggWpress
3 Jun 09 at 05:16
It’s a very simple and good idea. I must congratulates you because it’s not easy to find something original in WP plugin’s !
Li-An
3 Jun 09 at 08:36
@Li-An thanks!
Huseyin Berberoglu
3 Jun 09 at 08:37
@Douglas Hill If you add this code;
< ?php if (function_exists('wpfp_link')) { wpfp_link(); } ?>
to your single.php file it should work and show “add to favorites” link. I could not find any problem with this information. Please try again.
Plugin must work with all templates.
Huseyin Berberoglu
3 Jun 09 at 08:42
[...] WP Favorite Posts [...]
Weblog Tools Collection: WordPress Plugin Releases for 06/02 | Aslifm Blogu
3 Jun 09 at 08:49
Your plugin works nice but please, can you make it compatible with this one http://www.code-styling.de/english/development/wordpress-plugin-codestyling-localization-en
so the translation will be more easy ?
And it is not at all compatible with WP Minify
– too bad. http://omninoggin.com/projects/wordpress-plugins/wp-minify-wordpress-plugin/
Li-An
3 Jun 09 at 09:10
@Li-An I’ll look what should i do for these compatibilities. Thanks for suggestions.
Huseyin Berberoglu
3 Jun 09 at 09:31
Now I am really confused. Two favourited posts show up in the widget, but I still see no “Add to favourites” link. I am using Firefox 3, and refreshing the view.
Does it matter where I place the code in single.php?
Douglas Hill
3 Jun 09 at 13:48
I downloaded DynaBlue theme. There is a line like this in single.php;
Posted on : < ?php the_time('d-m-Y') ?> | By : < ?php the_author() ?> | In : < ?php the_category(', ') ?>
Add
< ?php if (function_exists('wpfp_link')) { wpfp_link(); } ?>
code after this line.
And if you use super cache plugin don’t forget to clean cache.
Huseyin Berberoglu
3 Jun 09 at 13:56
Thank you for your answer Huseyin. But I’m a little lost with all the different blogs you have. Is this now the official post for your plugin ? (because the link in the plugin does point to http://www.birazkisisel.com/wp-favorite-posts-released-en/)
Li-An
3 Jun 09 at 16:04
I was writing English and Turkish to birazkisisel.com. Then i decided to create a new blog which i’ll write only English. So here is new offical page of plugin.
I forgot to change url. It’ll change with next version.
Huseyin Berberoglu
3 Jun 09 at 16:08
btw is your problem solved ?
Huseyin Berberoglu
3 Jun 09 at 16:09
I still cannot get it to work with this theme. I tried it on my test blog running the same theme, and has very few plugins, and cannot get the link to appear.
I wish I could get it to work, because it is a great idea that would really be a wonderful feature in my blog.
Douglas Hill
3 Jun 09 at 21:49
@Douglas Hill;
I see “Add to favorites” link at this page; http://riverwriter.ca/wordcurrents/2009/05/26/giant/
Do you want to add link to your index.php ? I mean to http://riverwriter.ca/wordcurrents/ ? I you want this you should enter this code to your index.php;
< ?php if (function_exists('wpfp_link')) { wpfp_link(); } ?>
Huseyin Berberoglu
3 Jun 09 at 22:27
[...] WP Favorite Posts [...]
WordPress Plugin Releases for 06/02 | The Cliffmaster
4 Jun 09 at 10:26
We are getting somewhere, finally.
To get “Add to favourites to appear in all posts, I had to add to archives.php and index.php
Adding it to singlepost.php had almost no effect.
I like its position on the index page, but it is tangled in tags on the other pages, with no space between it and the previous tag.
Douglas Hill
4 Jun 09 at 14:04
@Douglas I think it will be better if you enter
code before Favorite posts link code
Huseyin Berberoglu
4 Jun 09 at 14:19
Yes, I have no problem. WP Minify gives the opportunity to exclude .js and .css files from its action and I did it with the files of your plugin. I will make a french translation of it very soon.
Li-An
5 Jun 09 at 10:01
[...] Berberoglu | blog Skip to content HomeProjectsWP Favorite Posts PluginBookmarkletsYour Favorite [...]
Huseyin Berberoglu | blog - Coming with next version
8 Jun 09 at 13:29
[...] 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. Visitor can see his/her favorite posts list from “Favorites” page which you created. [...]
7 x 24 Free ! - WordPress Plugin Releases, Updated Plugins
10 Jun 09 at 22:33
[...] WP Favorite Posts [...]
WordPress Plugin Releases for 06/02 - 7 x 24 Free !
12 Jun 09 at 10:30
If a post is only an image, and you save that image your favorite post page – is there a way to display that image again in the favorite post page…? As of now, it only shows the title of the post…
Thanks!
I will happily donate if I can get it working for my needs! thanks so much for your efforts…
Justin Young
12 Jun 09 at 20:12
hi!
I donated a little bit to the plugin, but I can’t figure out how to show thumbnail images on the favorites page. Every post is an image that is uploaded by the user, cropped into a thumbnail and displayed. If that image is saved to the favorites page, how do you show that thumbnail on the favorites page?
Thanks!
Justin Young
17 Jun 09 at 00:07
[...] WP Favorite Posts [...]
WordPress Plugin Releases for 06/02 | Fresh News - Blog Design, Wordpress, Blogger, and Web Development
17 Jun 09 at 03:25
Hi Huseyin,
Thanks for the advice on changing the plugin to show images in the favorites section. Your solution works if I attach an image to my post, but I’m using TDO Mini Forms where a user uploads an image to the server and posts to the front page. I guess the problem is in pulling the thumbnail that is generated via Get The Image plugin. I think it’s possible to pull this thumbnail from the database somehow, but don’t know how. Would you know how to do this?
Thanks again – and thanks for your time and efforts…
Justin
Justin Young
19 Jun 09 at 17:30
@Justin, i can’t figure out from outside. If you give me an access to your wp admin panel, i’ll look for your problem.
My email; hberberoglu ** gmail ** com
Huseyin Berberoglu
19 Jun 09 at 18:56
Love this plugin….exactly what I was looking for. One thing though….
Is it possible to display the users favourite posts in the sidebar as opposed to a seperate page?
Thanks!
Alan
24 Jun 09 at 20:06
Hi,
I use your plugin. It;s grate. I need put thumb on favorite list. Has anyone now haw to do it ?
Dawid
6 Jul 09 at 02:32
@Alan it is not possible right now. Maybe with next versions i can add a template code for this…
Huseyin Berberoglu
7 Jul 09 at 23:39
where i can see my favorites and also the other users own favorites¿
thanks
yli
22 Jul 09 at 04:49
Hi,
I couldn’t get this plugin to work by putting the code into single.php, so I’ve been adding the other code manually to each post. It loads that way, however it always reads ‘Favorite Loading’ before the ‘Add to favorites’ link. I’m pretty sure it’s not supposed to do that. Any suggestions?
Elise
29 Jul 09 at 18:59
Works great, thank you
baron
31 Jul 09 at 17:21
@yli create a page and insert {{wp-favorite-posts}} into content. You and your visitors will see favorites on this page.
Huseyin Berberoglu
31 Jul 09 at 17:23
@Elise you must insert
< ?php wpfp_link(); ?>code after the_title() function. It should work.Huseyin Berberoglu
31 Jul 09 at 17:24
Well, the plugin DOES work, mostly. It’s the before link image that doesn’t work for me. Instead of an image, the words Favorite Loading appear instead.
Elise
3 Aug 09 at 17:28
Great plugin, Huseyin!
One suggestion, for the “cookie_warning” message, that message should only be displayed for users who are not logged in or for users who are using cookies.
I wrapped the cookie_warning message in a !is_user_is_logged_in conditional, but if you can think of a better way to do this, that would be better!
-Ray
Ray
15 Aug 09 at 19:26
Thanks for your great plugin.
If you add a post the page loads in the same window with Added to favorites! text.How can i make it that the added to favorites and removed from favorites open in a popup or new window? (target=”blank”)
Thank you again
Peet
18 Aug 09 at 10:26
Great plugin. I am hoping I can use it so users can “claim” a page (e.g. a favorite club) and have their avatar/profile link show up on the page of the specific club. Does this sound like something that is possible? Visitors would see which users enjoyed this club.
The other thing is probably a mod, but I’m looking to have the list of clubs be in a separate table to generate pages from a single template (i.e. no separate WP page for each club listing). Where in the files would I look for the db or function references to use a different table that the WP pages table.
Thanks in advance.
TF
23 Aug 09 at 20:56
Hi Huseyin
looks like the ajax mode isn’t working on my site, please have a look: when adding a post to the favorites, the plugin returns a blank page with the success text
Any hint?
Thanks for this excellennt plugin!
olivier
2 Sep 09 at 06:34
Hi,
I have a few questions.
Firstly I want to make separate favourite lists, ie Favourite stores, favourite books etc.. Is it possible?
And also I would love to be able to create a small carousel/slider (maybe integrate with a plug in like WP Featured Content Slider) that shows images and the links for peoples favourites. It’s a lot to ask I know, and I am actually happy to pay to get this done as it would massively improve my site. Thanks so much in advance!
ddgdaily
11 Sep 09 at 13:37
Hi Huseyin, the plugin works well!
Is there a way to show the number of people who like a post under the post title, for instance “x people like this post”?
LC
19 Sep 09 at 14:30
hey Huseyin your plugin fits my needs perfectly. Everything works just fine, but I don’t know why the “Clear Favorites” function is no where to be found. Am I doing something wrong?
Bryan
21 Sep 09 at 22:12
I’m using your “My Favorites” plugin on my site and the viewers love it. I’d like to find out who is actually using it and what their favorites are but don’t want to make this information public using the widget. Is there a way to check the stats?
Steve Carter
5 Oct 09 at 18:00
Hello Huseyin,
I’m not sure if you still check this comments section but I am wondering if you could help me with something. I would like to have a widget that only displays the favorites posts of the user. I believe the way the widget works not is that it displays the most favorited posts as chosen by anyone who visits the site. Is this possible to do?
Your plugin is great and I plan on donating once I get my site up and running.
Any help you can provide me would be very much appreciated. Thank you!
Elias
25 Oct 09 at 06:39
How can I get the favorite image and the text to display on the same line? It’s almost like there is a break in there because the text appears to the side and underneath the image.
RenFromPenn
30 Oct 09 at 18:53
Okay, I managed to fix it by changing the attribute for vertical-align. Now what I need to know is why the add to favorites link is indented to the left and has a lot of extra spacing underneath. How can I fix both of those issues?
RenFromPenn
30 Oct 09 at 19:19
The previous problem is sorted out. It was a problem with the stylesheet for the theme and had nothing to do with this plugin.
RenFromPenn
30 Oct 09 at 22:08
On my favorites page, I would like to show images that link to the post instead of just printing out text links. Could you please tell me how to do that? I have thumbnails attached to each post, if that helps.
RenFromPenn
31 Oct 09 at 20:20
Is this plugin compatible with MU? I’d love to be able to save across my entire MU site.
Joseff
9 Nov 09 at 21:02
Very nice plugin!
But my dream, is an additional option: storing data in the database…
In the next version??
Vil
20 Nov 09 at 21:07
Nice Plugin. For my site I would users to be able to create and modify two separate “favorites” lists. So that a reader can click on two different “add to favorites links on one post which I can use to display two different lists on their miy favorites page.
Does anyone have an idea on how to best duplicate this plugin?
seth
15 Dec 09 at 22:19
I dont understand this
5. Create a page e.g. “Your Favorites” and insert text into content section. This page will contain users favorite posts.
What should i insert what text??? Do i insert a code into the page or what? Please somebody explain
ajlol
19 Dec 09 at 02:04
got it to work thx for plugin
ajlol
19 Dec 09 at 02:56
Great plugin Huseyin! Let me make a suggestion if you are interested in a donation or looking to make some extra money. I am looking for a trip planner plugin that allows a user to create a “My Trip” page complete with an option to get directions right on my website. The exact example I am looking for is the Trip Planner located at http://cityvisitor.com Judging by your plugin, I believe you have the skills to make this happen. Please email me and let me know
Burt Reynolds
24 Dec 09 at 23:24
Hello, I try to use this plugin on my blog (2.8.6) but I have a big problem when I active it. All my header shifts and curiously iformations concerning AddToAny are displayed, while AddToAny is not installed on my blog :/
Many thanks for your reply.
Lorand
11 Jan 10 at 01:38
Also, I think there is a problem with code in the wp-favorite-posts.php file (line 311, the <?php is not closed).
Lorand
11 Jan 10 at 03:08
How can I get the favorite list to display in an alphabetical order?
Sterf
14 Jan 10 at 15:46
Thanks a million for this plugin. I started using it on an accommodation booking site and people can now list their favourite accommodations as a reference.
I have 2 questions. Is it at all possible for future versions to consider using the typical wordpress shortcode instead of the the current code used to insert it into a page.
Secondly, I’m and trying to figure out a way of posting the results of the favourites list into a Contact form so users can send the site owner a list of their favourite posts.
That would take this plugin from great to even greater.
Thanks, if I find a solution I’ll let you know. Your advice would be appreciated though.
@nomadone
17 Jan 10 at 12:58
I think it’s a good idea to add simple pagination to manage favorites page… It doesn’t look good when there are too many posts added in favorites.
Levani
22 Jan 10 at 21:05
This is a great concept. I’m creating a site where I’d like people to be able to tag their favorite pages.
Is this possible?
Joceyn
3 Feb 10 at 05:04
This plugin is great but I’m having one problem – when I click on “add to favorites”, the loading graphic shows up and never stops. I’ve checked the “your favorites”, and the posts are not added to favorites. Any ideas?
breezyskies
5 Feb 10 at 21:00
@Elise i checked the plugin but i couldn’t any problem like you said. Can you send me a link?
Huseyin Berberoglu
7 Feb 10 at 03:03
@Ray, thanks for suggestion. I added this feature to my TODO list.
Huseyin Berberoglu
7 Feb 10 at 03:04
@Peet This processes are doing via AJAX normally. If ajax couldn’t work, you see only the “added to favorites” text.
Maybe i can add an option non-AJAX mode to future version.
Huseyin Berberoglu
7 Feb 10 at 03:06
@ddgdaily, it isn’t possible to make separate favourite lists. It’s a hard feature to implement. If you want to pay for modifications contact me via contact form.
Huseyin Berberoglu
7 Feb 10 at 03:09
Thank you for checking anyway, but I removed the plugin several months ago. I’ve since switched themes, and I may try it again someday. I’ll let you know if the same thing happens again at that time.
Elise
7 Feb 10 at 03:10
@LC there isn’t a way for “x people like this post”? text. I saw a plugin which doing this. you can try it -> http://wordpress.org/extend/plugins/i-like-this/
Huseyin Berberoglu
7 Feb 10 at 03:11
@Bryan You can see “clear favorites” text on your Favorites pages which you should create and insert
{{wp-favorite-posts}}code into it.Huseyin Berberoglu
7 Feb 10 at 03:12
@Steve Carter; Unfortunately there is only public statics for plugin for now. (most favorited posts)
Huseyin Berberoglu
7 Feb 10 at 03:14
@Elias yes it is possible to make. Please contact me for this.
Huseyin Berberoglu
7 Feb 10 at 03:15
@RenFromPenn this problem is about your theme’s css codes. If you try my plugin with Default theme you will see that there isn’t any problem.
Huseyin Berberoglu
7 Feb 10 at 03:16
@Sterf alphabetical order option isn’t available for now. maybe with next versions…
Huseyin Berberoglu
7 Feb 10 at 03:18
@nomadone; yes, you’re right. wordpress shortcode will be better.
i can’t find an answer for your second problem, i’m sorry :/
Huseyin Berberoglu
7 Feb 10 at 03:21
@Levani, thanks for pagination suggestion. i’m adding this to my TODO list. but i can’t say “i will do it soon”.
Huseyin Berberoglu
7 Feb 10 at 03:23
@Joceyn pages = posts there is no different. You can use this plugin in pages too.
Huseyin Berberoglu
7 Feb 10 at 03:24
@breezyskies, i think there is a problem with AJAX request. Can you send me a link which i can see this problem?
Huseyin Berberoglu
7 Feb 10 at 03:25