WP Favorite Posts
Can i maintain my favourites before & after login (5 posts)

  1. kpwpradnya
    Posted 3 years ago #

    I am new for wordpress, so this might be silly question but i need suggestion on this. I am using wp_favorite_post plugin,my question is if i am adding things into my favorites before login then is it get added into my wishlist after logged in?


  2. matthias_herbst
    Posted 3 years ago #

    I just wrote an extension for this plugin to automatically maintain favorites on login.


    add_action('wp_login', 'move_favorites_to_db');
    function move_favorites_to_db() {
    	$favorite_post_ids = wpfp_get_user_meta();
    	$favoriteIDs = array_keys(wpfp_get_cookie());
    	foreach($favoriteIDs as $favorite) {
  3. dylanhthomas
    Posted 2 years ago #

    Where do you put this code? I tried it in the main plugin file and my functions file, and it did not work.


  4. cfgmiller
    Posted 2 years ago #

    Did anyone else figure out how to get this working?

  5. Justina
    Posted 2 years ago #

    I am trying at the moment. Will post results if succeed.

    Honestly, I think it should be a setting in this plugin for this. Because now, when favorites are not maintained after login, we break the flow for the visitor. It is highly inefficient to make visitors mark their favorite posts once more.

    Dear author, please consider helping us, or updating plugin with this feature.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • WP Favorite Posts
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic