Welcome folks today in this blog post we will be
removing extension from filename using substr() and strrpos() functions in php 7. All the full source code of the application is shown below.
In order to get started you need to make an
index.php file and copy paste the following code
$filename = 'filename.php'; $filename_without_ext = substr($filename, 0, strrpos($filename, "."));