FOLLOW & UNFOLLOW. How many buttons do I use?

My site will have users who make a list of friends or follow players.

Do I use one button and change the function of that button depending if they want to follow or are following or want to unfollow…or do I create different buttons and only display based on the current state between the 2 players?

I’m having a chicken or the egg came first moment?



I would use one button and add two conditions, you can change the text, color etc of the button based on a condition.

when current user’s follow is ‘yes’
text: Unfollow
background: red

when current user’s follow is ‘no’
text: Follow
background: green

Or something along those lines, depending on how you have setup the follow system. But it is always easier to deal with one element in my opinion.

That is a good question. How do I set up the follow system. I was just thinking it would be a field with a list in the User data.

Do you have any suggestions?


I think there are plenty of examples of lists like these but I guess it would be a list of Users on the User object.

so when you click button ‘follow’ you will make a change to current user > ‘friends’ (list of Users) > add User.

Something along those lines from the top of my head.

Do you know of any examples that show adding friends and creating a situation where that person you add has to accept?

I’m a 100% rookie and trying to figure out this flow of info/data.

Thanks again!!

Well I would probably do something like:

Create two fields (of list of Users) on the user ‘Followers’ and ‘Pending Followers’

When a User clicks to ‘Follow’ another User, you make a change to the User that is getting followed, adding the current user to a list (Pending followers).

Then you have some sort of menu/notification where users see the Pending Followers and decide to authorize the follow. By clicking a button you remove the User from Pending Followers and add to the list of Followers.

For a “two sided” follow, I tend to use two lists, one of users who I follow, and another of users who follow me.

Then you can use “Intersects with” to show where it is complete.

This topic was automatically closed after 70 days. New replies are no longer allowed.