3

is there any way to add "follow" functionality to Wordpress ?

so that every logged-in user can follow his favorite author

and only can see post from authors that he followed them ..

A possible solution would be that if a logged-in user (call it user #1) is clicking "follow" on another user's profile (call it user #2), you record user #2's ID as meta data on user #1. You can do this via the update_user_meta function. You can then retrieve posts from user #2 by using WP_Query with an author parameter. The author parameter can be an array, so you can get the posts of multiple users that way

and maybe if we make this idea as a function called : "is_followed" which return True and False Then we can use it in index.php page in the following line :

<?php if( have_posts() ) : ?>
    <div class="entries">
        <?php while( have_posts()  ) : the_post(); ?>
            <?php get_template_part( 'content', get_post_format() ); ?>
        <?php endwhile; ?>
<?php endif; ?>

to be something like this:

<?php if( have_posts() ) : ?>
    <div class="entries">
        <?php while( have_posts() & is_followed  ) : the_post(); ?>
            <?php get_template_part( 'content', get_post_format() ); ?>
        <?php endwhile; ?>
<?php endif; ?>

Sorry I don't know how to write codes :(

I found a free plugin called: "User profiles" that can create a profile for each author: https://wordpress.org/plugins/user-profile/ so that we can put the follow button in it :/

4
  • 1
    Your question is actually too board. Explain what you have tried and narrow down where you are having problems and where you need help.
    – cybmeta
    Commented Jan 9, 2015 at 12:16
  • I need a code for adding "Follow" Functionality to multi author wordpress website :3 Commented Jan 9, 2015 at 12:20
  • That is really too board to be answered here. Sorry.
    – cybmeta
    Commented Jan 9, 2015 at 14:20
  • I've seen this type of functionality in the WP plugin archives. Have a browse through it and I am sure you can find alternatives. Search terms to use are Subscription and Follow...
    – Christine Cooper
    Commented Jan 10, 2015 at 0:46

2 Answers 2

1

Might be overkill, but you might want to take a look at BuddyPress - it's an actively developed project that extends WordPress with social networking features.

2
  • This does not provide an answer to the question. To critique or request clarification from an author, leave a comment below their post - you can always comment on your own posts, and once you have sufficient reputation you will be able to comment on any post. Commented Jan 10, 2015 at 10:09
  • 1
    BuddyPress has follow user functionality. It would adequately fulfill Sufyans needs. Commented Jan 10, 2015 at 12:50
1

This plugin allows logged in users to follow authors they choose. https://wordpress.org/plugins/wp-subscribe-author/

From the description...

Once subscriber starts follow the author, he will get notified all new post of author by email.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.