Update translation.html
Browse files- translation.html +6 -2
translation.html
CHANGED
@@ -60,7 +60,7 @@
|
|
60 |
Translate:</label>
|
61 |
<input type="text" class="form-control flex-grow-1" id="translationText2" value="My name is Wolfgang and I live in Amsterdam"
|
62 |
placeholder="Enter text" style="margin-right: 15px; margin-left: 15px;">
|
63 |
-
<button id="translateButton2" class="btn btn-primary"
|
64 |
</div>
|
65 |
|
66 |
<div class="mt-4">
|
@@ -117,7 +117,11 @@
|
|
117 |
|
118 |
*/
|
119 |
// Initialize the model after the DOM is completely loaded
|
120 |
-
|
|
|
|
|
|
|
|
|
121 |
</script>
|
122 |
</body>
|
123 |
|
|
|
60 |
Translate:</label>
|
61 |
<input type="text" class="form-control flex-grow-1" id="translationText2" value="My name is Wolfgang and I live in Amsterdam"
|
62 |
placeholder="Enter text" style="margin-right: 15px; margin-left: 15px;">
|
63 |
+
<button id="translateButton2" class="btn btn-primary">Translate</button>
|
64 |
</div>
|
65 |
|
66 |
<div class="mt-4">
|
|
|
117 |
|
118 |
*/
|
119 |
// Initialize the model after the DOM is completely loaded
|
120 |
+
|
121 |
+
window.addEventListener("DOMContentLoaded", (event) => {
|
122 |
+
initializeModel();
|
123 |
+
document.getElementById("translateButton2").addEventListener("click", translateText);
|
124 |
+
});
|
125 |
</script>
|
126 |
</body>
|
127 |
|