检查浏览器中支持特定的MIME类型? [英] Check if a browser supports a specific MIME type?
本文介绍了检查浏览器中支持特定的MIME类型?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何检查浏览器是否支持用php特定的MIME类型?
How can i check if the browser supports a specific mime type with php?
推荐答案
您可以分析的 接受的头字段,查看类型或该类型的超集列。
You could analyze the Accept header field to see if the type or a superset of that type is listed.
但是,受理通知书的是额定值的列表和的质量值表示不接受。和浏览器基于他们对于资源的预期(如 IMG
引用的资源要素预计将<$的元素发出不同的接受的值C $ C>图像/ * )。
But notice that Accept is a list of rated values and a quality value of 0 means not accepted. And browsers send different Accept values based on their expectations for that resource (e.g. a resource referenced in IMG
element is expected to be an element of image/*
).
这篇关于检查浏览器中支持特定的MIME类型?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文