Can I make Chat only show on certain pages?

Yes. By adding a bit of JavaScript with Page-Specific Variables, you can achieve this. This will affect both the chat box and the away form.

In this article

  1. Show chat on a single page
  2. Hide chat on a single page

Show chat on a single page

If you'd like for chat to only show on a few specific pages, you'll first need to enable the "Never show click to chat button" in Settings -> Chat -> Advanced.

You can then add the following line of JavaScript before the Lucky Orange tracking code on any page for which you'd like to show chat.

window.__wtw_lucky_show_chat_box = true; // Show Lucky Orange chat

Hide chat on a single page

If you want to hide chat, just add the following snippet before the Lucky Orange tracking code. In the code below, replace path/to/chat_disabled_page.html with the pathname of the page you want chat to hide on.

try {
    // If the current URL contains the name of my chat-disabled page
    if (window.location.href.indexOf("path/to/chat_disabled_page.html") > -1) {
        window.__wtw_lucky_no_chat_box = true; // Hide the chat box.
catch(ex) {}

Still need help? Contact Us Contact Us