[RESOLVED]Creating a follow and unfollow button like twitter

hi, i’ve tried searching online for this topic, but am yet to see one implemented in ASP.net Webpages.

I want to create a follow and unfollow button, for different users and also for different topics of interest.

If a user is being followed,there should be more priviledges, likewise topic…

I can handle the backend just fine. I only need suggestions,hints,and code snippet to make it work.

You need some way to determine if the current user is following the item or not. You might want to create an array of ids of followed items when the user logs in and store it in session. Then you can check the collection to decide whether to show a Follow
button/link or an Unfollow one. When the user clicks the button, you can use AJAX to update the list of followed items in the database and update the session object accordingly.

Leave a Reply