Hi all, how can I make it so that when an unregistered user enters an email into popup, the email is stored in cookies and the popup does not appear during the whole session?

Hi all, how can I make it so that when an unregistered user enters an email into popup, the email is stored in cookies and the popup does not appear during the whole session ?

Need local storage and do a search of DB to check if user is registered or not. Local storage or session storage will allow you to save the value and use across session.

maybe you can tell me how to do it?