Only show chat-badge on first pageview - or other custom rules
Hi
I would like to only show the chat-badge on specific pages and/or only on first page-view.
Is that possible ?
/Jacob
-
Hi Jacob 👋
That's perfectly possible with a little bit of Javascript.
If you want to extend it to just the firstpageview, you want to store a little bit of information in a Cookie, Localstorage, or you have that already somewhere else, and you can just add it to the IF statement.<script>
</script>
// let's hide the widget on load of page
zE('webWidget', 'hide');
// and show the widget on pages that have 'order' in the url
if (window.location.href.indexOf("order") > -1) {
zE('webWidget', 'show');
} -
Thanks for your quick reply.
But I think my description was not that good.
What I was trying to explain, was that I only want the normal Chat-button to be visible but not have the "Chat-badge" visible after first page view.
Your examples seem to hide the chat completely.
Is that possible ?
-
What do you mean by show the normal chat-button, and not the chat badge (maybe a screenshot will help)..?
Please sign in to leave a comment.
3 Comments