[英]Modal popup on window close using javascript/jquery
我有一个网站,客户可以在那里购买任何产品。 但是,有些客户没有进行任何购买就关闭了标签页。 我不想失去那些顾客。 因此, i have decided to provide offers for those customers in the "modal" popup. This popup has to be displayed once the customer clicks the close button in the browser
i have decided to provide offers for those customers in the "modal" popup. This popup has to be displayed once the customer clicks the close button in the browser
。 该popup will have a form
用于选择要约,填写其联系方式并提交表格。 提交表单后,可以自动关闭窗口。 是否可以提供这样的弹出模式。 我已经为此冲浪了。 每个人都对带有confirm
和alert
框的onbeforeunload
说。 谁能帮助我。
您尝试做的事情无法完成。 也就是说,在用户单击关闭后,将无法执行此操作。
但是我认为您正在寻找的是所谓的“退出意图弹出窗口”。
这个想法很简单:您使用js / jquery查找用户是否“即将”关闭页面(例如,通过鼠标移动等)并显示所述弹出窗口。
这是一个这样的插件: BIOEP
您可以使用Google“退出意图弹出窗口”进行更多操作。
您无法从页面代码中做到这一点,只能在扩展名中看到它。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.