note 91381 added to function.substr
| From: | info at xQmail dot eu | Date: | Tue, 09 Jun 2009 13:22:01 +0000 |
| Subject: | note 91381 added to function.substr | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-156606@lists.php.net to get a copy of this message | ||
in reply to: kaysar in ymail in com
If you want the filename without the extension, just use this:
<?php
$filename = substr($filename, 0, strrpos($filename, '.'));
?>
----
Server IP: 213.249.64.162
Probable Submitter: 84.245.2.253
----
Manual Page -- http://www.php.net/manual/en/function.substr.php
Edit -- https://master.php.net/note/edit/91381
Del: integrated -- https://master.php.net/note/delete/91381/integrated
Del: useless -- https://master.php.net/note/delete/91381/useless
Del: bad code -- https://master.php.net/note/delete/91381/bad+code
Del: spam -- https://master.php.net/note/delete/91381/spam
Del: non-english -- https://master.php.net/note/delete/91381/non-english
Del: in docs -- https://master.php.net/note/delete/91381/in+docs
Del: other reasons-- https://master.php.net/note/delete/91381
Reject -- https://master.php.net/note/reject/91381
Search -- https://master.php.net/manage/user-notes.php