【HELP】Show/hide button by login status

I’m a newbie who started developing in the bubble a few days ago.

I’m creating a profile site and I’m having trouble showing or hiding the [Edit Profile] button.

I would like the [Edit Profile] button to appear in the profile only when the logged in user looks at their own profile page.

Please advise.

Hey @r.gabby0706

Welcome to Bubble :slight_smile:

There are a number of ways you can accomplish this, and I’m not sure what your setup is, but here’s one way you could go about doing this: Let’s say that the content type of the page you’re talking about is set to User. You could untick the option on the Edit Profile button that says “this element is visible on page load” (so that the edit button is NOT visible on page load). Then, you could have a condition on the Edit Profile button that is something like this: “when current page user is current user…this button is visible”. (If the current user isn’t logged in, the condition will evaluate to “false” anyways, and the button won’t be visible). Hope this helps!

1 Like

Thanks for your share. It’s so good for me

1 Like

It worked perfectly.

Thank you so much.

1 Like

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