A
A
Alexander Vasyuchenko2015-02-17 11:58:32
telnet
Alexander Vasyuchenko, 2015-02-17 11:58:32

How to determine content type by URL?

Good afternoon!
There is such a link to the radio: http://roks.com:8000/live
In the browser and in the player it is reproduced without problems.
The task is how to determine the HTTP request or some other method that this is a link to a stream with sound (radio)?

I try like this:

telnet roks.com 8000
GET /live HTTP/1.1


And it returns me:

HTTP/1.1 400 Bad Request
Server: nginx/1.4.6 (Ubuntu)
Date: Tue, 17 Feb 2015 11:11:25 GMT
Content-Type: text/html
Content-Length: 181
Connection: close

<html>
<head><title>400 Bad Request</title></head>
<body bgcolor="white">
<center><h1>400 Bad Request</h1></center>
<hr><center>nginx/1.4.6 (Ubuntu)</center>
</body>
</html>

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
DevMan, 2015-02-17
@alexv1981

The link is not opening for me.
Trycurl -I http://shoutcast.byfly.by:88/russianradio

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question