Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I am trying to serve up mp4 / webm files using the native html5 video tag but my code does not seem to work on most browsers. I have identified the problem (adding MIME types to htaccess) but am not able to solve it.

Im on free shared hosting provided by my ISP... i cant run php on the server but i can host a lot of files there. For some reason it wont allow me to have my own .htaccess file either.

Is there any other way to force the server to apply the correct content-type to these files?

share|improve this question
    
Weird though... Chrome and Safari seems to stream the MP4 file even with the incorrect MIME type. IE9 does not play the MP4, Opera and Firefox wont stream the WEBM file either. –  Leo Quinn Apr 29 '11 at 1:33

1 Answer 1

There is a directive in the main apache config that controls whether the web server honours .htaccess files, and if it does, what overrides are allowed. Some ISPs are real strict about what they allow you to override. Some don't realize that they're being so strict, and so if you ask them to allow a specific directive in your .htaccess file, they may or may not allow it. But you have to ask.

share|improve this answer
    
BTW: I've found it helps a LOT if you can tell them exactly what they have to change in their Apache config to allow what you want to allow. –  Paul Tomblin Apr 28 '11 at 19:27
    
yeah i've noticed that i cannot upload files over 30mb either. Guess i could contact them and see what they can do. Was just hoping that there was some other way around it. Pointing to a html file and getting that to serve up the file with a specified MIME-type, or something like that. –  Leo Quinn Apr 28 '11 at 19:29

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.