How to save radio button progress and show completed steps when users return to dashboard? Answered
I want to build this similar kind of Get started in my website, any idea how we can capture the radio click session and show it when user comes to dashboard again later
If i have already done step 1, next time when i land on website it should show step one already done.
Comments
4 comments
Hi Mubassir,To achieve this, you would have to first create a custom field in Memberstack (in this example below, I called it 'selected-radio') to hold the progress, then update this progress each time the user completes a step. Afterwards, you can retrieve the radio button selection from the custom field in Memberstack.
Here's how you can implement this:
Implementation Steps
1. Retrieve Member Data: Use the Memberstack API to get the current member's custom fields.
2. Update Radio Button State: Set the radio button state based on the value retrieved from the custom field.
3. Update Member Data: When the user selects a radio button, update the corresponding custom field in Memberstack.
Here's a code snippet you'd have to place in the page to achieve your goal:
Explanation:
Notes:
Hi do you have any clonable or read only link?
it would help me a lot to solve this
Mubassir Shaikh, here's a cloneable which you can take inspiration from for the structure that you can follow and here's a cloneable from Memberstack which you can take design inspiration from. The latter is a bit more complex than your use-case, as the list is auto-checked based on the necessary actions being taken from the user, but both those cloneables should give you some ideas to customize. It's also best to use checkbox for such use-cases but if you want to use radio buttons, you can customize the cloneables further and follow the necessary steps as stated by Chukwudi above. Hope this helps.
Thankyou so much brother
Please sign in to leave a comment.