Comment 1 for bug 1038439

Revision history for this message
John Veness (pelago) wrote :

Having looked at the code some, I can think of a couple of ways to handle this. The first would be to add an attribute (sorry if that isn't the correct perl terminology) like the existing "extension" one to the config .pm files. It could be called mimetype, and could default to "video/mpeg" in the base config, and be overridden to "audio/mpeg" in MP3.pm or similar.

This value could be read by mythexport-daemon, and stored in the mythexport database table next to the other recording details, read later by mythexportRSS.cgi, and output to the RSS feed in the appropriate place. I do realise the would be changing the schema of the table, which can be awkward. As old rows in the table would have this column NULL, mythexportRSS.cgi could default to video/mpeg in such cases.

If changing the schema is undesired, I assume it is possible to look up, at runtime in mythexportRSS.cgi, a suitable MIME type from a file extension from somewhere.