How would you implement word pronounciation functionality in an online dictionary site ? for example lets say, oxforddictionaries.com. they have this functionality where you can listen to how the given words are being pronounced. Well, do I have to record each word and save it in a folder and then link it up with the database? If that's the case then probably I would have to create a million .wav or any sound files for the million words in the database. or how would I sort this out ? How do u think oxforddictionaries.com implemented this functionality ?
Asked
Active
Viewed 169 times
-6
-
1It seems like the oxforddictionaries.com recordings were done by people, so indeed you'd have to hire some voice actors to pronounce the words. This isn't really a PHP question though. – Ynhockey Oct 29 '12 at 12:11
-
the question is, how would you implement these kinda functionality in php, oxford site was just an example !! – XoR Oct 29 '12 at 12:13
-
1Still, this has nothing to do with php or ajax. – Karoly Horvath Oct 29 '12 at 12:15
-
3@XoR Being rude to the people who you are asking to help you is not going to get you very far. – vascowhite Oct 29 '12 at 12:17
-
check this http://stackoverflow.com/questions/5378126/wiktionary-api-for-pronunciation – arun Oct 29 '12 at 12:18
-
1yep apologies Mr Ynhockey .. !! – XoR Oct 29 '12 at 12:21
-
this isn't a programming question, you might be looking for library that can pronounce in machine way – Skuta Oct 29 '12 at 12:22
1 Answers
3
There are two approaches
- Record each word (wav/mp3)
- Synthesize the sound based on the phonetic spelling.
The latter one feels quite unnatural, but a cheap solution. I know only about the Longman dictionary, they definitely record each word (and even whole sentences), with a couple of speakers, so you don't get bored..
Unless you want to do the synthesis in a plugin/widget, you probably end up with sound files with both approaches. You can simply play them with html/html5/flash players.

Karoly Horvath
- 94,607
- 11
- 117
- 176