($file_name) = $path =~ /([^\\]*)$/;
But paths can often be seperated with "/", even in Windows. Modules usually know details like this, which is why it's usually important to use them. Refer to File::Basename.
($file_name) = $path =~ m#([^\\/]*)$#;
In reply to Re: Pattern matching
by ikegami
in thread Pattern matching
by ketema
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |