Forum Moderators: phranque
I have used this redirection script in .htaccess, to redirect them to a html:
RedirectMatch ^(.+)\celebrity.mp3$ http://www.example.com/index.html
It works fine, so long users arrive at the script from a web browser. But unfortunately most of my visitors come with a Real Player or Windows Media Player.Agent, .. and these players can not understand the redirection script.
Maybe the solution woud be a Rewrite engine script?
But I'm just a musician so I would greatly appreciate your help in this case.
Greetings from Denmark
Attila Kovacs
[edited by: jdMorgan at 2:58 pm (utc) on Nov. 15, 2006]
[edit reason] No sigs or URLs please. [/edit]
First, media players handle only "media files" such as MP3 and AVI, while browsers handle HTML, still images, JavaScript, and very little else -- using plug-ins to handle media files.
Second media players typically do not provide an HTTP Referer header, so you cannot tell if they clicked a link on your site or some other site in order to reach your media.
The first difference makes it difficult or even impossible to forcibly change media types -- like redirecting an <embed src="doremi.mp3">-tagged embedded media file to an HTML file which would normally be linked as <a href="doremi.html">.
The second difference makes it difficult to implement access control by referrer for media files, requiring more complex cookies-and-script solutions.
The bottom line is that for maximum client compatibility, you should not attempt to redirect or rewrite URLs of one MIME-type to those of a different MIME-type.
Jim