Could someone please explain exactly what this paragraph means? Sort of a “this paragraph for dummies” type of explanation.
“The only requirement for HTTP streaming is that your host server must recognize the .ra, .ram, .rm and .rpm mime types, which are standardized file classifications. Many servers already do. If not, it’s a relatively simple process to configure your host server for these mime types and you can request that your service provider add this feature for you.”
Why does the web server need to recognize special “mime types” for this to work? What is a mime type? HElp!
A mime type is just a type of file, like html or calendar entry or plain text, or jpeg graphic (there are tons of them). Servers can be configured to do certain things to different file types. For example, a web server may send .html files, execute .cgi files, and ignore requests for .txt files.
This paragraph is just saying that you must set your web server up to recognize and handle real audio files.
However, for the love of all that’s holy, please just say no to real audio.
To do HTTP streaming, your server (the host through which you communicate with the internet) must be set up to recognize that files ending in .ra, .ram, .rm and .rpm can be processed using a certain application, program or code. Just like Windows is set up to associate .txt files with Notepad and .html with Internet Explorer. If a .html file is invoked, Internet Explorer is called to handle it. Likewise, if the server sees one of those extensions, the defined code is called to deal with it.
If the host server is not configured and you are unable to configure it yourself, the service provider can do it. A service provider is the entity you pay for internet access such as AOL, Earthlink, Copper.net, etc…
[hijack]
Bill, I have a lot of respect for your expertise. Why are you not fond of real audio, and what do you prefer in its place & why?
I’m not a big-time MS-hater, but in general I try to favor anybody but them to give the market at least a little chance for innovation before they eat the apparent winner and squelch everyone else.
[/hijack]
Just to chime in. Don’t ever get sucked into that 25th level of hell that is RealMedia. It’s so awful that even MS products look significantly better.
The user software is so spyware ridden that many people refuse to install it on their computer. Ergo, you are significantly limiting your audience.
And on top of it all, their compression methods are really, really crappy. So why does anybody use it???
As to a really high quality, free, open source, runs on all the common platforms, audio format, use Ogg Vorbis. And it also does streaming. You pretty much can’t beat it.
You do? Another sucker falls prey to my charm and bullshit bravado. Thanks for the kind words.
My complaints with Real Audio:
it embeds itself like a virus; it’s way too hard to uninstall
It mandates that you give it an email address (and other personal stuff) to use it.
The trickery they use to sell their premium products
And on top of all that, they keep their formats proprietary, so you can’t play .rm files in Windows Media player for example.
In fairness, if I were in Real Audio’s shoes, I’m sure I’d do the same that they do. They have to really scramble, because the truth is they’re just another way to deliver files, and there’s absolutely zero technical advantage of what they have over any of the others. But that doesn’t mean that I as a consumer have to give them a break.
Others may not like this, but I prefer MS to deliver my browser and the stuff that comes through it along with my O/S. It’s much more convenient, and there really is no technical or quality advantage to using a competing component. Being a monopoly actually does bring some advantages to consumers, and complete solutions is the main one.
You may want to read my little rant about my not-so-wise choice to rip all 750+ of my cds in Ogg over here. I’m afraid it’s not a common platform where it’s very often needed, namely in personal players and car stereos.
Actually, in this case, it looks like no special processing happens on the server. All you need to do to make HTTP streaming of RealAudio work is tell the server that files ending in .ra and .ram (and .rm?) have the MIME type “audio/x-pn-realaudio”, and files ending in .rpm are “audio/x-pn-realaudio-plugin”. As far as the server is concerned, the RealAudio player is just another web browser downloading a file.
The server passes that information straight through to the client’s web browser, which is where the, er, real magic happens. A browser with the RealAudio plugin installed will see the MIME type, then hand the stream over to the RealAudio player, which plays the file as it downloads.
I don’t understand why the server would need a special setting. If the client computer receives a .ra file, doesn’t it already know to launch the real audio plugin to play it? Just as if it receives a .txt file it knows to launch notepad to read it?
Is the problem that the browser will attempt to open the file if the server doesn’t tell it otherwise?
The browser knows what to do with it because the HTTP header sent by the server contains a MIME type telling it what kind of file it is. The browser isn’t (shouldn’t be…) going strictly by file extension. In theory at least, you could make your TXT file use a .gobbledygook file extension as long as the server was configured to include the text/plain MIME type in the HTTP header for that extension. YMMV as some browsers may pay attention to the extension instead of the specified MIME type.
Hope I am not beating a dead horse. Just want to be clear.
So I have an mp3 file on my server. I type in its web address…and my computer immediately launches media player to play it (while it continues to download).
You are saying my computer does this, because of the Mime type in the http header? It doesn’t do it because it sees the .mp3 extension and simply knows what to do with such a file?
Correct. Notice that this SDMB page has the extension .php, and pages on other sites have extensions like .asp, .cgi, .shtml, etc. Pages on some sites like eBay even have the extension .dll. Your computer probably doesn’t know what .php, .asp, .cgi, or .shtml mean, unless you have a web server installed, and it has a totally different idea of what .dll means, but your browser is able to display the pages anyway because the server says “Content-type: text/html”.
Also, think about URLs like http://www.google.com/. What is the extension there? Your browser can’t figure out what the content type of that URL is supposed to be unless the server tells it.
This isn’t an example of MIME type the way I learned it. The server is simply set to automatically serve the index.html file if no file is specified. HTML is ascii text and MIME types are for non-ascii files. At least that is what mama says…
That’s true in general, but the thing is, your browser doesn’t know the server is serving a file called index.html. All it knows is it asked for http://www.google.com and the server sent back a “text/html” document.
And in fact, the server doesn’t have to have a file called index.html - it could be index.shtml, or index.php, or index.asp, or it could be generated on the fly and not exist as a file at all.
When you request a script like index.php, or when the server decides that it wants to serve the script to you for some reason, there are usually two MIME types involved. One is used to tell the web server that it’s a script - the server admin says something like “any file ending in .php has the type internal/x-php”, then “any file with the type internal/x-php should be passed through the PHP interpreter”. The other type is the content type of script’s output, which is determined by the script itself, and is usually text/html. (It could be anything, though - you could have one PHP script that generates HTML pages, another that generates ZIP files, and another that generates JPEG images. The MIME type decided by the script, not the script file’s extension, tells the browser what to do with it.)
All files have a MIME type, whether they’re binary or text. Plain text is “text/plain”, HTML is “text/html”.