summaryrefslogtreecommitdiff
path: root/morsecode/new 1.html
diff options
context:
space:
mode:
authormcd223 <jacob@simplelittledream.com>2019-02-07 19:38:42 -0500
committermcd223 <jacob@simplelittledream.com>2019-02-07 19:38:42 -0500
commit5552ce957b496dd4f0b8447dbfbf8718fbd1f2a7 (patch)
tree50243c695dfb3252fde70254e50087e54044583e /morsecode/new 1.html
redesign 3
Diffstat (limited to 'morsecode/new 1.html')
-rw-r--r--morsecode/new 1.html19
1 files changed, 19 insertions, 0 deletions
diff --git a/morsecode/new 1.html b/morsecode/new 1.html
new file mode 100644
index 0000000..6c834eb
--- /dev/null
+++ b/morsecode/new 1.html
@@ -0,0 +1,19 @@
+<script>
+<input id="text">
+<button onclick="talk()">Talk It!</button>
+<button onclick="listen()">Voice</button>
+<script src="../bower_components/platform/platform.js"></script>
+<script src="../src/webspeech.js"></script>
+<script>
+ var speaker = new webspeech.Speaker();
+ var listener = new webspeech.Listener();
+ function talk() {
+ speaker.speak("en", document.getElementById("text").value);
+ }
+
+ function listen() {
+ listener.listen("en", function(text) {
+ document.getElementById("text").value = text;
+ });
+ }
+</script> \ No newline at end of file