note 80536 deleted from function.filetype by tularis

From: Date: Mon, 21 Jan 2008 11:38:13 +0000
Subject: note 80536 deleted from function.filetype by tularis
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-135283@lists.php.net to get a copy of this message
Note Submitter: kayed at binaryinteractivestudios dot com Reason: useless ---- //you can get file extension through this function <?php function fileExtension($filename) { //check if this file exists and not a directory if(is_file($filename)) { $path_info = pathinfo($filename); /* echo $path_info['dirname'], "\n"; echo $$path_info['basename'], "\n"; echo $path_info['extension'], "\n"; echo $path_info['filename'], "\n"; // since PHP 5.2.0 */ return $path_info['extension']; } else { return false; } } ?>

« previous php.notes (#135283) next »