Hagsten / Talkify

Javascript Text to speech library
216 stars 32 forks source link

https://talkify.net ? #1

Closed glittle closed 7 years ago

glittle commented 8 years ago

Thank you for this wonderful service! I'm trying it out in a new site.

The voice is working fine but calls to the http://talkify.net API are failing because I'm using an https page. I've removed the .withTextHighlighting from the player, so it doesn't use GetPositions. I also have .forceVoice(xx) which correctly selects the voice to use. However, it still tries to use Language which fails.

Is there a chance that you could have an https API endpoint? Failing that, can I stop the call to the Language API?

glittle commented 8 years ago

In my local copy, I've adjusted playFromBeginning to not call to the Language api. I'm fine for now.

glittle commented 8 years ago

(Here's the page where it is working: https://wondrous-badi.herokuapp.com/verse)

Hagsten commented 8 years ago

First things first, I am glad that you find this to your liking! Secondly, Im glad that you have a working sample even though you encountered some issues along the way.

Regarding https, it is a good point, I will definitly concider that. An alternate route could be that you tunnel the calls through your own backend and just return the response. I.e. do an http-call behind the scenes. This solution needs some tweaking of the urls used by Talkify.

Good catch regarding the Language. There should be no need to call out for language if the voice is forced. I'll have that prioritized, in the meanwhile you can use your tweaked version.

Hagsten commented 7 years ago

@glittle as of version 1.1.0 you can turn off the use of remote services by using talkify.config.useRemoteServices = false. This will however limit you to use the Html5Player (i.e. the browsers built in SpeechSynth API) since the TtsPlayer needs to communicate with a remote host. Don't know if it will help you or not, but now you are aware of this config flag :).

inglesuniversal commented 7 years ago

Hi, I would like to VOTE in favor of an https:// connection since I open the target code inside a frame In the meantime I use target="_blank" so it opens an http:// connection. Hopefully I wish you can consider it in the coming weeks. cheapssl.com offers a 3 year ssl comodo certificate for 14 USD

hmatt1 commented 7 years ago

I'd like to see https as well. You can get free SSL certs from https://letsencrypt.org/

Hagsten commented 7 years ago

I will look into the SSL issue and I've been looking at letsencrypt. It will take some time for me to get to this issue due to other priorities, but I'll look at it asap. :)

Hagsten commented 7 years ago

Alright, @hmatt1 and @inglesuniversal have a try now, we are now responding to https-traffic. Let me know if it works good for you so that I can close this :).

hmatt1 commented 7 years ago

It works perfectly. Thank you!