How to display modal to users only one time/set-time to only display modal once?

Silver Contributor
Silver Contributor


Background, I'm currently using the modal offer ext + the js code ext (using the js ext >modal is shown after 5 seconds)

Would anyone know of a quick way using rules to display this modal only once to the user and then never display again?

 

Thanks!

3 REPLIES 3

How to display modal to users only one time/set-time to only display modal once?

Gold Contributor
Gold Contributor

If you have the ability to set a cookie then you can setup a flag with "true"/"false". 

for the initlial load cookie will be false and you will show the modal once the modal is shown change the value to true so it will never show up again.

 

VR

How to display modal to users only one time/set-time to only display modal once?

Bronze Contributor
Bronze Contributor

Hi @vinayreddy could you provide a more detailed description of how to set up this cookie and condition. I have a similar request to only show the modal to a user once per day. Thanks

How to display modal to users only one time/set-time to only display modal once?

Gold Contributor
Gold Contributor

Hi @zsullivan , When modal showed first time you can setup the cookie by writing document.cookie = "modal_show=true". And add a condition to your modal extension to show only when "modal_show=true" cookie not present. So, it will not load again and again.

If you want to show cookie once per day you can set cookie expire to one day. 

VR
Public