搜尋 Mozilla 技術支援網站

防止技術支援詐騙。我們絕對不會要求您撥打電話或發送簡訊,或是提供個人資訊。請用「回報濫用」功能回報可疑的行為。

了解更多

Opening attachments with unrecognised extensions

  • 1 回覆
  • 1 有這個問題
  • 11 次檢視
  • 最近回覆由 Matt

more options

We manufacture a system that uses specific configuration files with the extension .DUCX. We have developed our own app to use these files.

However, if a file XXX.DUCX is attached to an email and I double-click on it I am not asked which app to send it to. Instead it opens as a text file XXX.DUCX.TXT.

Thunderbird Options>>Files & Attachments allows the app for specific file types to be defined but doesn't offer the facility to add additional file types

We manufacture a system that uses specific configuration files with the extension .DUCX. We have developed our own app to use these files. However, if a file XXX.DUCX is attached to an email and I double-click on it I am not asked which app to send it to. Instead it opens as a text file XXX.DUCX.TXT. Thunderbird ''Options>>Files & Attachments'' allows the app for specific file types to be defined but doesn't offer the facility to add additional file types

所有回覆 (1)

more options

Actually it allows for specific media types to be defined. Media types for the windows educated are not file extensions and there have been some spectacular snafus created by developers that are unaware of this.

You will need to correctly encode your attachment as something other than plain text (which it is apparently encoded as now) if you want it to be recognized as something other than plain text be email clients and web browsers.

The link is for "registered media types" https://www.iana.org/assignments/media-types/media-types.xhtml

There was an addon for V68 that opened attachment by extension but it has not been updated for V78 and later. Perhaps you might get some mileage there as you develop software. https://github.com/HiraokaHyperTools/OpenAttachmentByExtension/tree/master/js