CODE
LIBARY.COM
Home
/
PHP
PHP Another way to get extension
Another way to get extension
<? $file = "test.html"; echo strtok(substr($file, -4, 4),"."); ?>
$file = "test.html"; echo strtok(substr($file, -4, 4),"."); ?>
Copy to Clipboard
Related Snippets
PHP Get current filename as variable
PHP "Check if Accessed from the Command-Line Interface (CLI) in PHP"
PHP Website Load Time
PHP Access Control for arunranga.com Domain - Web Resource
PHP Gravatar Image for 4nkitd@gmail.com
PHP Custom MIME Types for Web-Based File Uploads
PHP Count files in folder
PHP PHP Whois Query Function for Web-based Applications
PHP Add Post Images to RSS Feed in WordPress
PHP Text to Image using while