Expand my Community achievements bar.

SOLVED

Conditional Pop up

Avatar

Level 1

We need to create pop up in which there are two buttons 'Done' & 'Do it later'. If user clicks on 'Done' then pop up will never be shown to the user whenever user visits the page again.
We have tried capturing user click on done button by using two approach :
1.Session storage approach : User opens the website in one tab and clicks on done button and then opens the website in the next tab keeping the first session active then pop up is shown again.
2. Local storage approach: Using this approach the above issue is solved, but if the user clears the cache and cookies then on page visit up is seen again.
But we want that pop up is never shown to the user once done button is clicked.

1 Accepted Solution

Avatar

Correct answer by
Employee Advisor

Good idea @_Manoj_Kumar_ and storing the info server side could work if the popup is being shown after an authentication point.

 

If the popup is NOT behind an authentication step, I would use the local storage approach and not worry about the cache and cookie clearing scenario. By clearing their cache and cookies, they are saying that they want their browser to forget any previous history so showing the popup again after clearing cache and cookies is expected behavior.

View solution in original post

2 Replies

Avatar

Community Advisor

@Sandip_Choudhary1 How about storing this information server side? That should fix this issue.


     Manoj
     Find me on LinkedIn

Avatar

Correct answer by
Employee Advisor

Good idea @_Manoj_Kumar_ and storing the info server side could work if the popup is being shown after an authentication point.

 

If the popup is NOT behind an authentication step, I would use the local storage approach and not worry about the cache and cookie clearing scenario. By clearing their cache and cookies, they are saying that they want their browser to forget any previous history so showing the popup again after clearing cache and cookies is expected behavior.