Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Todd Merriman
October 23, 2008, 8:53 pm
rate this thread
echo "<embed src=\"http://sites.mydomain.com/cgi-bin/play.cgi?speech+1 \"
autostart=\"true\" hidden=\"true\" width=\"0\" height=\"0\">"
The browser requests the URL, and the server executes the CGI and sends
echo "Content-Type: audio/x-wav"
echo "Content-transfer-encoding: BINARY"
espeak --stdout "This is a test and only a test"
The espeak program does a text-to-speech conversion and outputs a WAV
stream. I can output the audio to a file and then serve the file, but
the results are the same.
Safari on a Mac plays the stream. Safari (and Firefox) on Windows XP
This is the header for the response received by the browser:
HTTP/1.x 200 OK
Date: Thu, 23 Oct 2008 20:32:16 GMT
Server: Apache/2.2.0 (Fedora)
- » How to increase web server uptime with DNS failover
- — Next thread in » HTML Authoring Forum