Update src/templates/index.html
Browse files- src/templates/index.html +1 -17
src/templates/index.html
CHANGED
|
@@ -85,7 +85,7 @@
|
|
| 85 |
</a>
|
| 86 |
</div>
|
| 87 |
<iframe
|
| 88 |
-
src="https://
|
| 89 |
class="chatbot-iframe"
|
| 90 |
id="chatbot-iframe"
|
| 91 |
frameborder="0"
|
|
@@ -101,22 +101,6 @@
|
|
| 101 |
console.error('Chatbot iframe not found.');
|
| 102 |
return;
|
| 103 |
}
|
| 104 |
-
// Detekcija jezika iz URL-a
|
| 105 |
-
const currentUrl = window.location.href;
|
| 106 |
-
let detectedLang = 'sr'; // Podrazumevani jezik je 'sr'
|
| 107 |
-
if (currentUrl.includes('/en/')) {
|
| 108 |
-
detectedLang = 'en';
|
| 109 |
-
} else if (currentUrl.includes('/zh-hans/')) {
|
| 110 |
-
detectedLang = 'zh-hans';
|
| 111 |
-
} else if (currentUrl.includes('/de/')) {
|
| 112 |
-
detectedLang = 'de';
|
| 113 |
-
} else if (currentUrl.includes('/ru/')) {
|
| 114 |
-
detectedLang = 'ru';
|
| 115 |
-
} else if (currentUrl.includes('/sr/')) {
|
| 116 |
-
detectedLang = 'sr';
|
| 117 |
-
}
|
| 118 |
-
const chatbotUrl = `${cb.src}?lang=${detectedLang}`;
|
| 119 |
-
cb.src =chatbotUrl;
|
| 120 |
|
| 121 |
setTimeout(() => {cb.contentWindow.postMessage({
|
| 122 |
screenWidth: window.innerWidth,
|
|
|
|
| 85 |
</a>
|
| 86 |
</div>
|
| 87 |
<iframe
|
| 88 |
+
src="https://dwpwcbg5ll92p.cloudfront.net"
|
| 89 |
class="chatbot-iframe"
|
| 90 |
id="chatbot-iframe"
|
| 91 |
frameborder="0"
|
|
|
|
| 101 |
console.error('Chatbot iframe not found.');
|
| 102 |
return;
|
| 103 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 104 |
|
| 105 |
setTimeout(() => {cb.contentWindow.postMessage({
|
| 106 |
screenWidth: window.innerWidth,
|