How to save a variable value when you leave a page and return to it

Hi,

Great question!
You can definitely store values per session, but you will need to use Corvid to get it done.

Here are a few type of storage you can use:

  • Local: Data in local storage never expires, even if the site visitor closes your page. When the visitor reopens the page later, the data can still be retrieved. You can store up to 50kb of data in local storage.

  • Session: Data in session storage is available while the site visitor’s web session is active. The session ends when the visitor closes the browser tab or window. When the session ends, all the data in session storage is lost. Reloading or restoring the page does not affect session storage data. You can store up to 50kb of data in session storage.

  • Memory: Data in memory storage is available as long the site visitor does not refresh or close the page. Reloading or restoring the page clears the memory storage data. You can store up to 1mb of data in memory storage.

You can check out some documentation on storing data here: wix-storage-frontend - Velo API Reference - Wix.com