现在的位置: 首页 > 综合 > 正文

取文件后缀的函数

2013年12月04日 ⁄ 综合 ⁄ 共 389字 ⁄ 字号 评论关闭
/*********************************************************************
  函数名称: getPostfix
  功能描述: 取文件后缀
  被访问表: none
  被修改表: none
  输入参数: $filename ----------------- 文件名
  输出参数: $postfix ------------------ 后缀
  函数返回: str
  其他说明: 2004-9-17
**********************************************************************/
function getPostfix($filename)
{
 $postfix = substr(strrchr(trim(strtolower($filename)),"."),1);
 Return $postfix;
}

抱歉!评论已关闭.