Pat LeSmithe wrote: > On 10/18/2009 10:07 AM, William Stein wrote: > >> On Sun, Oct 18, 2009 at 5:10 AM, Wilfried Huss <[email protected]> >> wrote: >> >>> Linking to an external video file works as expected. But if I >>> try to use an ogg theora video, which is uploaded into the DATA >>> directory, as the source of the <video> element, the file is not >>> recognized. I suspect that the notebook webserver does not >>> use the correct Mimetype for ogv files. >>> >>> I have a test worksheet at: >>> http://www.sagenb.org/home/pub/755/ >>> >> I don't know why it doesn't work. Maybe something needs to be changed >> in notebook/twist.py or something else having to do with >> Twisted.web2... >> > > The system file /etc/mime.types may be out of date. On my Fedora 10-ish > machine, I upgraded from > > mailcap-2.1.28-1.fc9.noarch.rpm > > to > > mailcap-2.1.29-2.fc11.noarch.rpm > > A local notebook server now sets the header "Content-Type: video/ogg" > for an .ogv file --- the video works in Firefox 3.5.3. > > Looking at > > http://wiki.xiph.org/MIME_Types_and_File_Extensions > > I think the relevant entries in /etc/mime.types are > > application/ogg ogx > audio/ogg oga ogg spx > video/ogg ogv > Thanks, adding the ogv entry to /etc/mime.types fixes the problem in Mandriva.
I've now added a patch to #7298 which adds Ogg Theora support for animations. -- Wilfried > From > > http://twistedmatrix.com/trac/browser/trunk/twisted/web2/static.py > > def loadMimeTypes(mimetype_locations=['/etc/mime.types']): > """ > Multiple file locations containing mime-types can be passed as a list. > The files will be sourced in that order, overriding mime-types from the > files sourced beforehand, but only if a new entry explicitly overrides > the current entry. > """ > > Adding, e.g., > > static.loadMimeTypes(['/path/to/updated/mime.types']) > > near the top of sagenb.notebook.twist.py may also work. > > > > --~--~---------~--~----~------------~-------~--~----~ To post to this group, send an email to [email protected] To unsubscribe from this group, send an email to [email protected] For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---
