While most of the time I'd just use file_get_contents
and CURL, I can't get it to work with a port in the URL. How can I read this file?
http://174.120.124.178:7800/7.html (It's a shoutcast statistics file)
Ultimately, I just want the text after the last comma.
It has nothing to do with the port. They're blocking you because you're not using a browser user agent.
curl
does let you fake the user agent, but that may be a violation of the site's terms of service.According to this post it's not about blocking scripts, but just distinguishing between Shoutcast clients and everything else. So the code is: