Reputation: 13907
I'm setting up a podcast. For cross-browser support, I currently need to upload a mp3 file and an ogg file. I'd like to simplify that process to uploading one of many audio files, that converts on the server into one mp3 and one ogg, then drops it into a folder. Is this possible?
Thanks!
Upvotes: 1
Views: 5758
Reputation: 3537
For your purpose you need to use ffmpeg for the conversion and eventually ffmpeg-php.
Like:
<?php
system ('ffmpeg -i /tmp/a.wav -ar 22050 /tmp/a.mp2', $retval); // took from the ffmpeg documentation. it's just an example
// add " > /dev/null &" if you want to execute in background
?>
Upvotes: 1