Summary: | XML/HTML | ||
---|---|---|---|
Product: | shared-mime-info | Reporter: | Sebastien Bacher <seb128> |
Component: | freedesktop.org.xml | Assignee: | Jonathan Blandford <jrb> |
Status: | RESOLVED INVALID | QA Contact: | |
Severity: | normal | ||
Priority: | high | CC: | bugzilla, sbrabec |
Version: | unspecified | ||
Hardware: | x86 (IA32) | ||
OS: | Linux (All) | ||
Whiteboard: | |||
i915 platform: | i915 features: | ||
Bug Depends on: | 2692 | ||
Bug Blocks: |
Description
Sebastien Bacher
2004-06-06 09:28:30 UTC
This problem seems to be bigger then just HTML files. XML files can be many different types of files (XSL, XHTML, NRG, Mime-type database). Are there plans for supporting mime-type detection based on the used doctype or primary xmlns? This does seem to go beyond simple file header magic though, perhaps a seperate routine for XML files? Let mime-types have an optional "xmlns" attribute perhaps? The base XML mime-type should only be used as a fall-back for unknown forms of XML. *** Bug 1321 has been marked as a duplicate of this bug. *** There's already data to match against when trying to detect XHTML files, for example: <mime-type type="application/xhtml+xml"> <sub-class-of type="application/xml"/> <_comment>XHTML page</_comment> <glob pattern="*.xhtml"/> <root-XML namespaceURI='http://www.w3.org/1999/xhtml' localName='html'/> </mime-type> If your XHTML files don't mention http://www.w3.org/1999/xhtml in the namespace, then they need fixing. If detecting by data for those XML files still fails, then it's probably a bug in the implementation, so you'd need to file a bug against gnome-vfs, or whatever bit of code is responsible for detecting mime-types in your desktop environment. |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.