Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
実際のファイル拡張子を特定したいと思います。
例 :
file = "test.fakeExt" // but the real extention is .exe // for security reason I wish to avoid using it!
どうやってやるの?
拡張子を特定したい場合は、findmimefromdata を使用できます。ファイルの最初の部分を調べて、ファイルの種類を判断します。
FindMimeFromData 関数
サンプルコード