Hiding the chat widget via API Follow

Comments

3 comments

  • Avatar
    Oscar Jimenez

    Hello, sorry I am not developer, I want to only show the zendesk chat on some pages of our website, but I can't, customer service couldnt help me, they gave me this script but it didnt work.

     

    <script>
     
    var url = (window.location.href);
     
     
    {
    $zopim(function() {
    $zopim.livechat.hideAll();
    });
    }
     
    else {
    $zopim(function() {
    $zopim.livechat.window.show();
    $zopim.livechat.button.show();
    });
    }
    </script>
     
     
    I will thank you your help.
     
    Regards
  • Avatar
    Darwin Stephenson

    You can do this with Google Tag Manager. Instead of loading the Zendesk Script in your header, load Zendesk via GTM and then trigger it to fire on the pages you desire.

  • Avatar
    rogelli

    How can I hide widget in free plan via API script. please provide example. shall it be at the start of the widget script? thanks

Please sign in to leave a comment.

Powered by Zendesk