in reply to Extracting names from string

You mean, you want to extract the part between the slash and the pipe?
I'd do it this way:
my($name) = $string =~ m!/([^|]+)\|!/;