Blog Archives

Customize form validation by using jQuery validation plugin

Capture

Sometime form validation is trouble thing for building front page, in this article briefing a method which allow us to customize the validation by adding ourselves’ rule.

Posted in HTML5, Javascript Tagged with: ,

Create a jQuery plugin to make your web as a speaker

web-speech-api

I there anyway to make your web text content spoken?

There are a lot of APIs we can use, but it is not easy to choose a suitable one. I tried with google translate speech api (e.g:http://translate.google.com/translate_tts?ie=UTF-8&q=what+are+you+doing&tl=en-us), but there is a limitation that the length of sentence can not be longer than 100 characters for one time call. Anyway we can split our large content into array of sentences and every item is one sentence which shorter than 100 characters. Then loop the array to call google’s API, but another problem raises up, google will cancel our call because the frequency is too high.

Posted in Digital Multiple Media, Javascript Tagged with: ,