legojedi Posted July 28, 2007 Share Posted July 28, 2007 I can not figure out the reason why this does not go past step 2, it will not go to 2a. Any help would be greatly appreciated. The ultimate goal here is to save a text to speech into a wav or mp3 file. <?php $Engine = new COM("SAPI.SpVoice"); $File = new COM("SAPI.SpFileStream"); echo "1</br>"; $File->Open("C:\\Website\\Test\\5.wav", 3, false); echo "2</br>"; $Engine->AllowOutputFormatChangesOnNextSet = false; echo "2a</br>"; $Engine->SetOutput($File,true); echo "2b</br>"; $Engine->SetOutput($File); echo "3</br>"; $Engine->Speak("Hello World!", SPF_DEFAULT); echo "4</br>"; $File->Close(); echo "5</br>"; $File->Close(); unset($File); unset($Engine); ?> Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.