This is not a real solution - it is not portable. Please use File::Basename. Having said that...
Update: Thank you Chris, the code should be:my $a = "foo/bar/baz"; my ($file) = $a =~ /\/(.*?)$/;
my ($file) = $a =~ m|/([^/]+)$|;
In reply to Re: Re: Getting the filename from full path name ?
by pbeckingham
in thread Getting the filename from full path name ?
by peterr
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |