//首先导入该js
<script type='text/javascript' src='/pcQuery/js/WebSpeech.js'></script>
//第二步:在你需要读取的地方执行就ok
<script>
$(function(){
WebSpeech.ready(function() {
WebSpeech.server = 'http://120.24.87.124/cgi-bin/ekho2.pl';
WebSpeech.setVoice('en');
WebSpeech.speak('你好,欢迎使用WebSpeach!');
});
})
</script>
js下载地址:
链接:https://pan.baidu.com/s/1Mfqw3wU07Qw5PL--xwLtxw 密码:59ar