Hi there
is it possible to show the teaser via a custom trigger rather than the main popup? I can trigger the main popup easy enough but couldn’t see how to trigger the teaser only ??
thanns
Hi there
is it possible to show the teaser via a custom trigger rather than the main popup? I can trigger the main popup easy enough but couldn’t see how to trigger the teaser only ??
thanns
Best answer by bluesnapper
Hi
An interesting use case!
Adding to
Klaviyo captures form submitted events but no events are captured when it’s viewed. If you use the example code below, when someone clicks your web button, the pop-up appears, and an event is created called ‘Viewed Form’ for that profile that has the value of the FormID (in this case that is SafHJf. Replace all references to SafHJf to the ID of your form.
Then create a segment to select profiles who have clicked the web button/viewed form (example for formID SafHJf below, substitute your FormID).
Duplicate your form but as a standard teaser/pop-up with the following configuration:
The outcome should be:
Note, this will only work for cookied users i.e they have a Klaviyo profile
As I mentioned, please check my logic and test!
Hope that helps.
Regards
Andy
Custom trigger web button/event
<center><button class="klaviyo_form_trigger">Click for pop-up</button></center>
<script type="text/javascript">
document.querySelector('.klaviyo_form_trigger').addEventListener('click', function (){
window._klOnsite = window._klOnsite || [];
window._klOnsite.push(['openForm', 'SafHJf']);
var klaviyo = klaviyo || [];
var item = {
"FormID": "SafHJf",
};
klaviyo.push(["track", "Viewed Form", item]);
});
</script>
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.