contenttype 模块

此文件是Web2py Web框架的一部分
版权所有:Massimo di Pierro<mdipierro@cs.depaul.edu>

根据freedesktop.org的共享mime信息数据库1.1版创建的content_-type字典。

偏离官方标准:
  • .md:application/x-genesis-rom-->text/x-markdown

  • .png:image/x-apple-ios-png->image/png

添加物:
  • .load:文本/html

  • .json:应用程序/json

  • .jsonp:应用程序/jsonp

  • .pickle:应用程序/python pickle

  • .w2p':应用程序/w2p

gluon.contenttype.contenttype(filename, default='text/plain')[源代码]

返回与给定文件名扩展名匹配的内容类型字符串。