Jump to content


Photo

How to strip the extension


  • Please log in to reply
1 reply to this topic

#1 komquat

komquat
  • Members
  • PipPipPip
  • Advanced Member
  • 130 posts
  • LocationHoughton, MI

Posted 04 March 2006 - 03:22 PM

I am looking for advice on how to strip an extension of a file name.

example

File name: lighthouse.jpg

I want to get: lighthouse

Thanks again

#2 kenrbnsn

kenrbnsn
  • Staff Alumni
  • Advanced Member
  • 8,235 posts
  • LocationHillsborough, NJ, USA

Posted 04 March 2006 - 03:36 PM

Look at the functions [a href=\"http://www.php.net/path_info\" target=\"_blank\"]path_info[/a]() and [a href=\"http://www.php.net/basename\" target=\"_blank\"]basename[/a]().

Ken




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users