Kiểu MIME .pptx: application/vnd.openxmlformats-officedocument.presentationml.presentation

Các file có đuôi .pptx (Microsoft PowerPoint) dùng kiểu MIME application/vnd.openxmlformats-officedocument.presentationml.presentation.

Cập nhật

application/vnd.openxmlformats-officedocument.presentationml.presentation
Kiểu MIME của .pptx
Tài liệu
Danh mục
Không
Nén bằng gzip/Brotli

Kiểu MIME của file .pptx là gì?

Kiểu MIME (media type) của file Microsoft PowerPoint có đuôi .pptx là application/vnd.openxmlformats-officedocument.presentationml.presentation. Đây là file Office Open XML dựa trên định dạng ZIP.

Header Content-Type

Content-Type: application/vnd.openxmlformats-officedocument.presentationml.presentation; charset=utf-8

Các kiểu dựa trên văn bản nên có charset để trình duyệt giải mã ký tự đúng cách.

Cấu hình máy chủ

Máy chủCấu hình
Nginx (mime.types or types {})application/vnd.openxmlformats-officedocument.presentationml.presentation pptx;
Apache (.htaccess)AddType application/vnd.openxmlformats-officedocument.presentationml.presentation .pptx
IIS (web.config)<mimeMap fileExtension=".pptx" mimeType="application/vnd.openxmlformats-officedocument.presentationml.presentation" />
Node.js / Expressres.type('pptx') hoặc res.setHeader('Content-Type', 'application/vnd.openxmlformats-officedocument.presentationml.presentation; charset=utf-8')
Amazon S3Đặt Content-Type: application/vnd.openxmlformats-officedocument.presentationml.presentation trên đối tượng (metadata), hoặc truyền --content-type application/vnd.openxmlformats-officedocument.presentationml.presentation vào aws s3 cp

File .pptx có nên nén không?

Không. File Microsoft PowerPoint đã được nén sẵn bên trong, nên gzip hay Brotli chỉ tốn CPU và hầu như không giảm dung lượng — đôi khi còn làm tăng. Hãy loại application/vnd.openxmlformats-officedocument.presentationml.presentation khỏi cấu hình nén của bạn.

Vì sao kiểu MIME quan trọng

Trình duyệt quyết định cách xử lý một phản hồi — hiển thị, thực thi, phát hay tải xuống — dựa trên header Content-Type, chứ không phải đuôi file. Với X-Content-Type-Options: nosniff, kiểu sai sẽ khiến stylesheet và script bị chặn hoàn toàn. Với file tải lên, đừng bao giờ tin kiểu do client gửi; hãy kiểm tra nội dung file (magic bytes) ngay trên server.

Câu hỏi thường gặp

MIME type của .pptx là gì?
application/vnd.openxmlformats-officedocument.presentationml.presentation.
Làm sao đặt Content-Type cho .pptx trong Nginx?
Đảm bảo application/vnd.openxmlformats-officedocument.presentationml.presentation pptx; có trong khối types (thường nằm ở /etc/nginx/mime.types) rồi tải lại Nginx.
Có nên gzip file .pptx không?
Không — định dạng này đã được nén sẵn, nên nén HTTP không mang lại lợi ích gì.