Hello. I need to configure that when a user logs into the site for the first time, he accepts cookies. Never worked before, where do I start? How do I set it up correctly?
Hi Yana. Have you tried the Cookies plugin? If that does not work, you can build your own:
Add a floating group fixed to the bottom with the message and buttons that you need (accept, decline, etc).
On pageload, verify if the user ever accepted it; if not, use the Show element action.
Then when they choose an option, use that to Make changes to the User, toggling a field to “yes” (as to not show the cookie popup to users that have accepted it already);
Then hide the floating group.
Alternatively, if you want to improve it, you can change that to a different data table called “user-device” with fields like browser, operating system, etc (there’s plugins like Browser Device Information if you’re not yet familiar with JS) and then the option the user selected.
You can save that record in the user’s table when he chooses a button to accept the cookies and validate. That way, you’ll have more info to provide if he questions it.
but I need the system to check if the user used cookies or not, even if the user was logged in and logged out or the user is not logged in
Bubble creates a “temporary user” even before they sign up. You can save it with the Make changes to the current user, and use it to validate pages or even elements in your landing page by making them not visible, and conditional to “accepted_cookies”=yes to display them.
Once that user signs up with that same device, the data will be moved to his actual user record.
Maybe you could describe to me in more detail how to implement?
This topic was automatically closed after 70 days. New replies are no longer allowed.