I'm trying to work out a method of capturing a live MP3 audio stream, i.e. internet radio/Icecast or Shoutcast, and saving the captured audio in defined file lengths, so 1 hour audio file, or 2 hour audio file.
I found something on this thread using bash and wget (Record radio / audio stream (asx/asf) with a webserver), but I want to build a PHP script that is more customisable, and I can trigger via cron job.
I figured using something like stream_get_contents(), but I've never used it before.
Any ideas?
Thanks