Skip to content

Instantly share code, notes, and snippets.

@yEzas
Forked from arafathusayn/hidetdo.js
Last active August 5, 2019 10:43
Show Gist options
  • Save yEzas/3620862a28fdff2a9e272ca8ef338bb3 to your computer and use it in GitHub Desktop.
Save yEzas/3620862a28fdff2a9e272ca8ef338bb3 to your computer and use it in GitHub Desktop.
Hide Tidio Chat Branding
function hideTdo() {
var timer = null;
var target = document.querySelectorAll('#tidio-chat iframe')[0];
if(!target || typeof target === 'undefined') {
if(timer !== null) {
clearTimeout(timer);
}
timer = setTimeout(hideTdo, 500);
return;
} else {
var timer2 = null;
var tdo = document.querySelectorAll('#tidio-chat iframe')[0].contentWindow.document.querySelectorAll('div.input-group a.powered')[0];
if(!tdo || typeof tdo === 'undefined') {
if(timer2 !== null) {
clearTimeout(timer2);
}
timer2 = setTimeout(hideTdo, 1);
return;
}
document.querySelectorAll('#tidio-chat iframe')[0].contentWindow.document.querySelectorAll('div.input-group a.powered')[0].style.display = 'none';
setInterval(function(){ hideTdo(); }, 1);
return true;
}
}
hideTdo();
@bertusjwz
Copy link

Thanks! It's been a while when I was trying to do this. Where do I place this code again? Can you help me with that?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment