javascript - How to show pop-up then user close page use js -


i have broblem.

situation - user first time visited in site. user want close page (not go anover page, close). site have pop comprising offer discounts.

i need show pop befor user left site.

use onbeforeunload method.

window.onbeforeunload = function(){     return 'your message here.'; }; 

Comments

Popular posts from this blog

c# - Unity IoC Lifetime per HttpRequest for UserStore -

Change the color of an oval at click in Java AWT -

I am trying to solve the error message 'incompatible ranks 0 and 1 in assignment' in a fortran 95 program. -