# Need some help..!

**URL:** <https://forum.adalo.com/t/need-some-help/87>\
**Category:** Get Help\
**Created:** [January 3, 2020, 11:54am UTC](https://forum.adalo.com/t/need-some-help/87 "2020-01-03T11:54:49Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![ishantanusrivastava](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.adalo.com/ishantanusrivastava/32/34947_2.png) [@ishantanusrivastava](https://forum.adalo.com/u/ishantanusrivastava)\
**Post date:** [January 3, 2020, 11:54am UTC](https://forum.adalo.com/t/need-some-help/87/1 "2020-01-03T11:54:49Z")

</div>

I created an app where users can post something in the text form. so what I’m not able to do is two things i.e.,

1. How can I set database where I’m able to show the user-posted data to all users who use my app (Logged)

2. Like system for the text, they (user) posted

**Please refer database as A,B & so on.**

---

<div class="post-metadata">

**Author:** ![spellytics](https://avatars.discourse-cdn.com/v4/letter/s/3ec8ea/32.png) [@spellytics](https://forum.adalo.com/u/spellytics)\
**Post date:** [January 10, 2020, 8:30am UTC](https://forum.adalo.com/t/need-some-help/87/2 "2020-01-10T08:30:25Z")

</div>

Hiya,

Hopefully this will help.

Step 1. You would need at least the following collections  
**#1 Users**  
Where people sign up / login.

**#2 Collection B - I will refer to this as Posts**  
This is the database you should point to when user submit their post.  
This collection should have the following properties:

- Post ID
- Post (for text they write)
- Image or some media they upload

Step 2. Go to Collection B and create a relationship property with the Users collection.  
This relationship indicates the owner of the post - let’s call this property **Posted by**.  
Users can have multiple Posts, but a Post can have one user.  
Everytime you create a record for the Posts collection, you should also update the **Posted by** with the current logged in user’s user id.

Step 3. Go to Collection B and create another relationship property with the Users collection.  
Users can have multiple Posts, and a Post can have multiple users.  
This relationship indicates who liked the post - let’s call this property **Likes**.  
You can have a **Like** button that have action which will update the Post collection to add the logged in user to this **Likes** column. To show how many likes a post can have, you can use the formula to Count the number of users in the **Likes** property.

---

<div class="post-metadata">

**Author:** ![ishantanusrivastava](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.adalo.com/ishantanusrivastava/32/34947_2.png) [@ishantanusrivastava](https://forum.adalo.com/u/ishantanusrivastava)\
**Post date:** [January 11, 2020, 9:14am UTC](https://forum.adalo.com/t/need-some-help/87/3 "2020-01-11T09:14:31Z")

</div>

Hey thanks for your help but one thing i’m still facing is a logged in user can able to click the icon more than once that means when they like the post more than once it count all the **hits**.

Icon \> Clicks \> Update the current record \> Likes + 1

Above mention method i’m using for now.

**Main thing i’m looking to develop**

When user click the icon, the icon will inactive & changed the color.  
And if user once again clicked it then back to previous count.

For example -  
User clicked \> (Collection Property - 10 ) +1 = (Collection Property - 11) \>  
User once again clickes on the same icon \> (Collection Property - 11 ) -1 = (Collection Property - 10)

---

<div class="post-metadata">

**Author:** ![parker](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.adalo.com/parker/32/6097_2.png) [@parker](https://forum.adalo.com/u/parker)\
**Post date:** [January 15, 2020, 1:27am UTC](https://forum.adalo.com/t/need-some-help/87/4 "2020-01-15T01:27:04Z")

</div>

Hi! I was able to do this by creating two like buttons on top of each other with conditional visibility. I also added a relationship between posts and users and called it ‘likers’ so I could keep track of who liked it. Here’s how it works:

**Like Button (unclicked)**

- only visible if likes does not contain logged in user
- click action: add user to likes

**Like Button (clicked)**

- only visible if likes contains logged in user
- click action: remove user from likes

This way, the button acts like a toggle that changes when you click it. You could make one of them a different color to indicate whether or not it has been clicked yet. Does that help?

---

<div class="post-metadata">

**Author:** ![Tommen](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.adalo.com/tommen/32/5383_2.png) [@Tommen](https://forum.adalo.com/u/Tommen)\
**Post date:** [May 19, 2020, 11:31am UTC](https://forum.adalo.com/t/need-some-help/87/5 "2020-05-19T11:31:31Z")

</div>

Hello Parker,  
I am trying to implement this in my app but I keep struggling. Do you think you could please make a short video or more detailed message on how to achieve this? Thanks!

---

<div class="post-metadata">

**Author:** ![AJAY](https://avatars.discourse-cdn.com/v4/letter/a/f4b2a3/32.png) [@AJAY](https://forum.adalo.com/u/AJAY)\
**Post date:** [May 20, 2020, 3:41am UTC](https://forum.adalo.com/t/need-some-help/87/6 "2020-05-20T03:41:53Z")

</div>

This link is to a simple setup: [How to Allow Users to Follow Others - Adalo Resources](https://help.adalo.com/how-to/how-to-allow-users-to-follow-others)

If you need something more complex (I’m using an external data source), here is my setup:

---

<div class="post-metadata">

**Author:** ![Arun](https://avatars.discourse-cdn.com/v4/letter/a/ee7513/32.png) [@Arun](https://forum.adalo.com/u/Arun)\
**Post date:** [May 20, 2020, 4:34am UTC](https://forum.adalo.com/t/need-some-help/87/7 "2020-05-20T04:34:49Z")

</div>

The video doesn’t play. Could you upload again?

---

<div class="post-metadata">

**Author:** ![Arun](https://avatars.discourse-cdn.com/v4/letter/a/ee7513/32.png) [@Arun](https://forum.adalo.com/u/Arun)\
**Post date:** [May 20, 2020, 6:49pm UTC](https://forum.adalo.com/t/need-some-help/87/8 "2020-05-20T18:49:16Z")

</div>

the video works now. good stuff Ajay

---

<div class="post-metadata">

**Author:** ![Tommen](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.adalo.com/tommen/32/5383_2.png) [@Tommen](https://forum.adalo.com/u/Tommen)\
**Post date:** [May 20, 2020, 7:02pm UTC](https://forum.adalo.com/t/need-some-help/87/9 "2020-05-20T19:02:16Z")

</div>

Thank you Ajay, great stuff!
