mahara=> SELECT * FROM artefact_file_files;
artefact | size | oldextension | fileid | filetype
----------+----------+--------------+--------+-------------
14 | 302059 | flv | 14 | video/flv
27 | 13833263 | flv | 27 | video/x-flv
Did the following to get the x-flv's to show up:
INSERT INTO artefact_file_mime_types (mimetype, description) VALUES ('video/x-flv', 'flv');]]>
Thanks for your response! Here's what's in the artefact_file_mime_types table:
> SELECT * FROM artefact_file_files WHERE artefact=14;
artefact | size | oldextension | fileid | filetype
----------+--------+--------------+--------+-----------
14 | 302059 | flv | 14 | video/flv
I adding video/flv to artefact_file_mime_types using the following statement:
INSERT INTO artefact_file_mime_types (mimetype, description) VALUES ('video/flv', 'flv');
And it shows up! I could have sworn that I tried that before, but I must have mistyped something somewhere. Thanks again!
]]>If you have a look in the artefact_file_files table for one of those files, you will be able to see the mime type presented by the browser when the file was uploaded.
If you add this mime type into artefact_file_mime_types with the description 'flv' (either directly in the database or by editing and reloading filetypes.xml) then they should appear for inclusion in the embedded media block. You should also check the internal media block configuration in the admin area under 'administer extensions' to make sure flv is not disabled there.
The problem might be if it's uploaded with something wishy-washy and generic like application/octet-stream. If it's common for browsers to do that then I guess we'll have to just show pretty well everything in the embedded media block and leave it to the user to choose something sensible.
ii file 4.26-2ubuntu3
ii libmagic1 4.26-2ubuntu3
I've uploaded a sample file to a public-facing site:
http://jamesmallen.net/wp-content/uploads/random/Counting%20Leader.flv
The FLV was created in Adobe Premiere Pro, using the Adobe Media Encoder, and uploaded to Mahara from Firefox 3.0.10 on Windows XP SP3, if any of that matters. As I mentioned before, Mahara is running on a fairly plain Ubuntu 9.04 Server edition inside a VM. Thanks for your help!
]]>I think this might be related to some other issues people were having with this blocktype. There's already a bug open about it (bug 3242) - I'll link this post to it. Do you have a video available that is detected as video/x-flv that we could use for testing? Also, what is your version of file (and libmagic if you can get that)? You can find out by running dpkg -l | grep [packagename]
]]>After some poking around, I think it may have to do with the fact that the file command on this version of Ubuntu does not give the expected output for an FLV that I've uploaded. Instead of "application/x-flash-video", it returns "video/x-flv".
I tried adding a row manually to artefact_file_mime_types for x-flv, but that didn't seem to help. I removed the row, then tried forcing an upgrade by editing artefact/file/filetypes.xml and artefact/file/version.php, but I have a feeling I messed something up somewhere.
Any insight into how this can be fixed? Thanks in advance!
]]>