Content-Typeheader中的"qs=0.001"是什么?
What is "qs=0.001" in the Content-Type header?
我正在检查 content-type header 以确定页面是否为 PDF。
通常,PDF 的内容类型为 application/pdf
。但是,页面:https://www.w3.org/WAI/ER/tests/xhtml/testfiles/resources/pdf/dummy.pdf
告诉我:content-type: application/pdf; qs=0.001
什么是qs=0.001
?我在 specs.
中没有找到对它的任何引用
我应该用 contentType === "application/pdf" || contentType.startsWith("application/pdf;")
替换我的 contentType === "application/pdf"
支票吗?
我找到了这个
https://lists.w3.org/Archives/Public/ietf-http-wg/2002AprJun/0037.html
看起来是在 HTTP 级别。
希望对您有所帮助。
我正在检查 content-type header 以确定页面是否为 PDF。
通常,PDF 的内容类型为 application/pdf
。但是,页面:https://www.w3.org/WAI/ER/tests/xhtml/testfiles/resources/pdf/dummy.pdf
告诉我:content-type: application/pdf; qs=0.001
什么是qs=0.001
?我在 specs.
我应该用 contentType === "application/pdf" || contentType.startsWith("application/pdf;")
替换我的 contentType === "application/pdf"
支票吗?
我找到了这个 https://lists.w3.org/Archives/Public/ietf-http-wg/2002AprJun/0037.html
看起来是在 HTTP 级别。
希望对您有所帮助。