Skip to content

Instantly share code, notes, and snippets.

@viggy28
Created January 3, 2026 07:32
Show Gist options
  • Select an option

  • Save viggy28/1cb067842ba9251724fddb1d0ee8c66a to your computer and use it in GitHub Desktop.

Select an option

Save viggy28/1cb067842ba9251724fddb1d0ee8c66a to your computer and use it in GitHub Desktop.
<!-- MyClone Widget for Hostinger (Horizon) -->
<!-- Open your index.html file in Horizon -->
<!-- Find the closing </body> tag and paste this code right before it -->
<script>
(function() {
var config = {
mode: "bubble",
expertUsername: "YOUR_USER_NAME",
personaName: "YOUR_PERSONA_NAME",
widgetToken: "YOUR_WIDGET_TOKEN",
position: "bottom-right",
primaryColor: "#817156",
bubbleText: "Chat with me",
enableVoice: true,
welcomeMessage: "Hello! How can I help you?"
theme: {
primaryColor: "#817156",
textColor: "#111827"
},
};
function initWidget() {
if (window.MyClone) {
window.MyClone(config);
}
}
var existingScript = document.querySelector('script[src*="myclone-embed.js"]');
if (existingScript) {
initWidget();
return;
}
var script = document.createElement('script');
script.src = 'https://app.myclone.is/embed/myclone-embed.js';
script.async = true;
script.onload = initWidget;
script.onerror = function() {
console.error('Failed to load MyClone widget');
};
document.body.appendChild(script);
})();
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment