PageSourceSearch

https://www.comex.go.cr/scripts/miscelaneos/talkify.js

js comex.go.cr collected 2026-09-24 21:07:15 UTC 1,844 bytes, 47 lines download raw bytes

1$(document).ready(function() {
2var sAgent = window.navigator.userAgent;
3var Idx = sAgent.indexOf("MSIE");
4        $('#leer').click(function(){
5            var text = '';
6            if (window.getSelection) {
7                text = window.getSelection().toString();
8            } else {
9                text = $('#test').val();
10            }
11            
12          // If IE, return version number.
13          if (Idx > 0 || !!navigator.userAgent.match(/Trident\/7\./)) {
14            
15            talkify.config.remoteService.host = 'https://talkify.net';
16            talkify.config.remoteService.apiKey = '9b1c6ae9-8220-4613-916c-96c98b180750';
17
18            talkify.config.ui.audioControls = {
19                    enabled: true, //<-- Disable to get the browser built in audio controls
20                    container: document.getElementById("player-and-voices")
21            };
22                var player = new talkify.TtsPlayer()
23                                .enableTextHighlighting();
24                
25                player.playText(text);
26
27                //var playlist = new talkify.playlist()
28                                //.begin()
29                                //.usingPlayer(player)
30                                //.withRootSelector('body')
31                                //.withTextInteraction()
32                                //.build()
33                                //.play();
34          }
35          else{
36                    var msg = new SpeechSynthesisUtterance();
37                    var voices = window.speechSynthesis.getVoices();
38                    msg.voice = voices[0];
39                    msg.rate = 10 / 10;
40                    msg.pitch = 1;
41                    msg.volume = 1;
42                    msg.text = text;
43                    speechSynthesis.speak(msg);
44          }
45        });
46});
47                

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.