Reputation: 109
I recently built a website with a full background video, but when running in Firefox or IE it doesn't work online (offline is fine). It works fine with chrome, but when it comes to IE or Firefox I only have a white background. Firefox spits out this error
HTTP "Content-Type" of "text/plain" is not supported. Load of media resource http://www.sweetsunnyvibes.com/assets/christmas_snow.webm failed.
So, I created a text file, renamed it .htaccess, and pasted these three lines in there. Nothing else is in this document. The document is in the root folder of the website, next to the index.html, and above my 'assets' folder which contains the video.
AddType video/webm .webm
AddType video/ogg .ogv
AddType video/mp4 .mp4
Still nothing. Am I doing something wrong?
There is also a strange bug with the volume mute controls (tied to a HTML5 audio player) not working on firefox, but working fine on IE and GC. They are controlled with a function like this:
function muteCheck() {
var audioElm = document.getElementById('player');
audioElm.muted = !audioElm.muted;
};
If anyone could help me out it would be greatly appreciated.
Upvotes: 0
Views: 315
Reputation: 944084
The error is caused by the server claiming that the file contains plain text.
The .htaccess
changes didn't do anything so one or more of the following are probably true:
Upvotes: 1