We know there are certain situations where you may want to hide the chat department drop-down selection on the pre-chat form altogether.
Good News! It's achievable by adding the below custom web widget script code to your help centre or external website.
Follow these steps:
- Add the script underneath the standard web widget script before the closing header tag </header>
- Click Save to save the changes.
<!-- Start of Zendesk Web Widget Customization -->
<script type="text/javascript">
window.zESettings = {
webWidget: {
chat: {
departments: {
enabled: []
}
}
}
};
</script>
<!-- End of Zendesk Web Widget Customization -->
If you already have some custom javascript for your web widget in place, you can simply combine the above code with your existing code. See the example below:
<!-- Start of Zendesk Web Widget Customization -->
<script type="text/javascript">
window.zESettings = {
webWidget: {
contactOptions: {
enabled: true,
contactFormLabel: { '*': 'Raise a ticket' }
},
chat: {
departments: {
enabled: []
}
}
}
};
</script>
<!-- End of Zendesk Web Widget Customization -->
Example of the custom web widget script in the help centre theme page code:
RESULTS
Before:After:
successCX.com can help you achieve your Customer Service objectives, driving better customer experiences and repeat business. successCX.com is an official Master Zendesk Implementation and Solutions partner.