What is MIME type "application/vnd.oasis.opendocument.graphics-flat-xml"?
A MIME type is a string that tells browsers and other tools how to handle a particular kind of file.
application/vnd.oasis.opendocument.graphics-flat-xml specifies a file format used for vector graphics. Flat XML means the content is stored in plain, readable XML form rather than in a compressed package.
This format is part of the OpenDocument standard. It is ideal for storing and sharing complex graphics while keeping the file text-based for easier edits and version control.
- Supports precise vector graphics storage.
- Allows direct editing with text editors.
- Facilitates integration in XML-based workflows.
- Promotes compatibility through open standards.
Files using this MIME type have the FODG extension. They are used by various office and drawing applications to create detailed graphics.
Learn more about the standard at OASIS OpenDocument Format.
Associated file extensions
Usage Examples
HTTP Header
When serving content with this MIME type, set the Content-Type header:
Content-Type: application/vnd.oasis.opendocument.graphics-flat-xml
HTML
In HTML, you can specify the MIME type in various elements:
<a href="file.dat" type="application/vnd.oasis.opendocument.graphics-flat-xml">Download file</a>
Server-side (Node.js)
Setting the Content-Type header in Node.js:
const http = require('http');
http.createServer((req, res) => {
res.setHeader('Content-Type', 'application/vnd.oasis.opendocument.graphics-flat-xml');
res.end('Content here');
}).listen(3000);
Associated file extensions
FAQs
What is the difference between a .fodg and a .odg file?
The standard .odg file is a compressed ZIP container holding multiple XML files and assets, while .fodg (Flat OpenDocument Graphics) is a single, uncompressed XML file. The application/vnd.oasis.opendocument.graphics-flat-xml MIME type is used for the latter, making it human-readable and easier to track in version control systems like Git.
Which applications can open files with this MIME type?
Files served as application/vnd.oasis.opendocument.graphics-flat-xml are primarily opened by LibreOffice Draw and Apache OpenOffice Draw. Because the content is plain XML, developers can also open and inspect these files using standard text editors like Notepad++ or Visual Studio Code.
How do I configure Apache to serve .fodg files correctly?
To ensure browsers recognize the file type, add the following line to your .htaccess file or main configuration: AddType application/vnd.oasis.opendocument.graphics-flat-xml .fodg. This ensures the server sends the correct Content-Type header instead of defaulting to text/xml or application/octet-stream.
Can web browsers display application/vnd.oasis.opendocument.graphics-flat-xml directly?
No, most modern web browsers (Chrome, Firefox, Edge) do not natively render OpenDocument Graphics files. When a user clicks a link with this MIME type, the browser will typically prompt to download the file. To display the graphic on a webpage, you should convert the file to a standard web format like SVG or PNG.
Why would I use the Flat XML format instead of the standard compressed format?
The Flat XML format is ideal for programmatic generation and version control. Since the file is plain text rather than a binary blob or ZIP archive, diff tools can easily show changes between versions, and scripts can modify the graphics properties without needing to unzip and re-zip the file.
What are the security implications of this MIME type?
Since this format is XML-based, it is theoretically susceptible to XML External Entity (XXE) attacks if processed by a poorly configured parser. Always ensure your software (like LibreOffice) is up to date, and validate input if you are building an application that parses these files automatically.
How do I add support for this MIME type in Nginx?
You can add the MIME type definition inside the types block in your nginx.conf file. Add the line: application/vnd.oasis.opendocument.graphics-flat-xml fodg;. After saving the file, reload Nginx to apply the changes.
General FAQ
What is a MIME type?
A MIME (Multipurpose Internet Mail Extensions) type is a standard that indicates the nature and format of a document, file, or assortment of bytes. MIME types are defined and standardized in IETF's RFC 6838.
MIME types are important because they help browsers and servers understand how to process a file. When a browser receives a file from a server, it uses the MIME type to determine how to display or handle the content, whether it's an image to display, a PDF to open in a viewer, or a video to play.
MIME types consist of a type and a subtype, separated by a slash (e.g., text/html, image/jpeg, application/pdf). Some MIME types also include optional parameters.
How do I find the MIME type for a file?
You can check the file extension or use a file identification tool such as file --mime-type on the command line. Many programming languages also provide libraries to detect MIME types.
Why are multiple MIME types listed for one extension?
Different applications and historical conventions may use alternative MIME identifiers for the same kind of file. Showing them all helps ensure compatibility across systems.