php取得文件扩展名

  1. function GetFiletype($filename){
  2. $filer=explode(".",$filename);
  3. $count=count($filer)-1;
  4. return strtolower(".".$filer[$count]);
  5. }