I know php well and I use javascript and jquery but I don\'t seem to know how to make a speech to text conversion with them though, but i do know that there are many flash speec
You could have a look at speechapi.com and build yourself what you need but if its the other way around;text to speech,speak.js will do.
Hope that helps.