Opera and HTML5 video

AntonAL picture AntonAL · Apr 4, 2011 · Viewed 7.5k times · Source

On my website, I have video in mp4 and ogv formats. mp4 plays in webkit browsers. ogv plays in Firefox, but don't want in Opera.

There is a trivial HTML:

<video poster="my_video.jpg" controls="controls">
    <source src="my_video.mov" type="video/mp4" />
    <source src="my_video.ogv" type="video/ogg; codecs='theora, vorbis'" />
</video>

When i open up a page, i see video element with poster, but when i'm clicking play button, nothing happens. I don't see loading progress and everything still as is. But Firefox plays it fine.

In Opera's network inspector, i see following HTTP Header for .ogv video file request:

GET /my_video.ogv HTTP/1.1

User-Agent: Opera/9.80 (Macintosh; Intel Mac OS X 10.6.7; U; ru) Presto/2.7.62 Version/11.01

Accept: text/html, application/xml;q=0.9, application/xhtml+xml, image/png, image/jpeg, image/gif, image/x-xbitmap, /;q=0.1

"Accept" part is confusing me. Why it accepts these content types for video ?

Any ideas ?

Answer

karlcow picture karlcow · Apr 4, 2011

For Opera, you really only need to have these two mime types added to Apache or any server you would be using.

AddType video/ogg .ogv
AddType audio/ogg .oga

Is this video working for you? Do you have a link to the video you are trying to play?